Compare commits

...

5 Commits
2.0.6 ... 2.0.9

Author SHA1 Message Date
Joxit
21e3ad51af fix(warn): Refused to get unsafe header "www-authenticate" 2021-09-13 09:14:00 +02:00
Joxit
73613a3b96 fix: The tag seo is not a recognized Liquid tag. 2021-09-11 15:52:51 +02:00
Joxit
6da744a9c5 ci: add major and patch tag versions 2021-08-25 07:48:41 +02:00
Joxit
db6b74a5f0 fix(docker-image): minor typo for sha256
fixes #201
2021-07-13 23:32:57 +02:00
Joxit
840a00e32b fix(demo): multi-arch image example is now working 2021-07-04 00:12:30 +02:00
7 changed files with 36 additions and 22 deletions

View File

@@ -15,9 +15,15 @@ jobs:
run: npm install
- name: Build the interface
run: npm run build
- name: Current tag
id: current-tag
- name: Major tag
id: major-tag
run: echo "::set-output name=tag::$(git describe --tags | grep -o '^[0-9]*')"
- name: Minor tag
id: minor-tag
run: echo "::set-output name=tag::$(git describe --tags | grep -o '^[0-9]*\.[0-9]*')"
- name: Patch tag
id: patch-tag
run: echo "::set-output name=tag::$(git describe --tags | grep -o '^[0-9]*\.[0-9]*\.[0-9]*')"
- name: Download kokai
run: curl -sSL https://github.com/Joxit/kokai/releases/download/$(curl -sSL https://api.github.com/repos/Joxit/kokai/releases/latest | jq -r ".tag_name")/kokai-linux-x86_64 > kokai
- name: Create Release Note
@@ -51,7 +57,9 @@ jobs:
push: true
tags: |
joxit/docker-registry-ui:latest
joxit/docker-registry-ui:${{steps.current-tag.outputs.tag}}
joxit/docker-registry-ui:${{steps.major-tag.outputs.tag}}
joxit/docker-registry-ui:${{steps.minor-tag.outputs.tag}}
joxit/docker-registry-ui:${{steps.patch-tag.outputs.tag}}
- name: Build and push Latest Debian Version
uses: docker/build-push-action@v2
with:
@@ -61,4 +69,6 @@ jobs:
push: true
tags: |
joxit/docker-registry-ui:debian
joxit/docker-registry-ui:${{steps.current-tag.outputs.tag}}-debian
joxit/docker-registry-ui:${{steps.major-tag.outputs.tag}}-debian
joxit/docker-registry-ui:${{steps.minor-tag.outputs.tag}}-debian
joxit/docker-registry-ui:${{steps.patch-tag.outputs.tag}}-debian

1
.gitignore vendored
View File

@@ -6,3 +6,4 @@ registry-data
_site
*.orig
.serve/
demo/v2

View File

@@ -12,4 +12,6 @@ defaults:
- scope:
path: ""
values:
image: /screenshot.png
image: /screenshot.png
plugins:
- jekyll-seo-tag

File diff suppressed because one or more lines are too long

View File

@@ -1,6 +1,6 @@
{
"name": "docker-registry-ui",
"version": "2.0.6",
"version": "2.0.9",
"scripts": {
"start": "ROLLUP_SERVE=true rollup -c -w",
"build": "rollup -c",
@@ -14,21 +14,21 @@
"license": "AGPL-3.0",
"description": "A web UI for private docker registry",
"devDependencies": {
"@babel/core": "^7.12.9",
"@babel/preset-env": "^7.12.7",
"@riotjs/compiler": "^5.3.1",
"@babel/core": "^7.14.6",
"@babel/preset-env": "^7.14.7",
"@riotjs/compiler": "^5.4.2",
"@riotjs/observable": "^4.0.4",
"@riotjs/route": "^7.0.0",
"@riotjs/route": "^7.1.2",
"@rollup/plugin-babel": "^5.2.2",
"@rollup/plugin-commonjs": "^17.0.0",
"@rollup/plugin-html": "^0.2.3",
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-node-resolve": "^11.0.0",
"core-js": "^3.9.1",
"js-beautify": "^1.13.0",
"riot": "^5.3.1",
"riot-mui": "joxit/riot-5-mui#4d68d7f",
"rollup": "^2.34.2",
"@rollup/plugin-node-resolve": "^11.2.1",
"core-js": "^3.15.2",
"js-beautify": "^1.14.0",
"riot": "^5.4.5",
"riot-mui": "github:joxit/riot-5-mui#4d68d7f",
"rollup": "^2.53.1",
"rollup-plugin-app-utils": "^1.0.6",
"rollup-plugin-commonjs": "^10.1.0",
"rollup-plugin-copy": "^3.4.0",

View File

@@ -64,7 +64,7 @@ export class DockerImage {
return this.fillInfo();
});
this.on('get-sha256', function () {
if (this.size !== undefined) {
if (this.sha256 !== undefined) {
return this.trigger('sha256', this.sha256);
}
return this.fillInfo();
@@ -98,7 +98,7 @@ export class DockerImage {
oReq.addEventListener('loadend', function () {
if (this.status == 200 || this.status == 202) {
const response = JSON.parse(this.responseText);
if (response.mediaType === 'application/vnd.docker.distribution.manifest.list.v2+json' && !response.layers) {
if (response.mediaType === 'application/vnd.docker.distribution.manifest.list.v2+json' && self.opts.list) {
self.trigger('list', response);
const manifest = response.manifests[0];
const image = new DockerImage(self.name, manifest.digest, { ...self.opts, list: false });

View File

@@ -53,7 +53,8 @@ export class Http {
case 'loadend': {
self.oReq.addEventListener('loadend', function () {
if (this.status == 401 && !this.withCredentials) {
const tokenAuth = parseAuthenticateHeader(this.getResponseHeader('www-authenticate'));
const tokenAuth =
this.hasHeader('www-authenticate') && parseAuthenticateHeader(this.getResponseHeader('www-authenticate'));
self.onAuthentication(tokenAuth, (bearer) => {
const req = new XMLHttpRequest();
req._url = self._url;
@@ -65,7 +66,7 @@ export class Http {
req.setRequestHeader(key, self._headers[key]);
}
if (bearer && bearer.token) {
req.setRequestHeader('Authorization', `Bearer ${bearer.token}`)
req.setRequestHeader('Authorization', `Bearer ${bearer.token}`);
} else {
req.withCredentials = true;
}