diff --git a/actions/push-images/__tests__/docker.test.ts b/actions/push-images/__tests__/docker.test.ts index 626b5cd7..c94ca304 100644 --- a/actions/push-images/__tests__/docker.test.ts +++ b/actions/push-images/__tests__/docker.test.ts @@ -157,129 +157,129 @@ describe('buildCommands', () => { 'docker load -i /images/fluentd-2.9.4-linux-amd64.tar', 'docker tag grafana/fluentd:2.9.4-amd64 grafana/fluentd:latest-amd64', 'docker push grafana/fluentd:latest-amd64', - 'docker tag grafana/fluentd:2.9.4-amd64 grafana/fluentd:v2-amd64', - 'docker push grafana/fluentd:v2-amd64', - 'docker tag grafana/fluentd:2.9.4-amd64 grafana/fluentd:v2.9-amd64', - 'docker push grafana/fluentd:v2.9-amd64', + 'docker tag grafana/fluentd:2.9.4-amd64 grafana/fluentd:2-amd64', + 'docker push grafana/fluentd:2-amd64', + 'docker tag grafana/fluentd:2.9.4-amd64 grafana/fluentd:2.9-amd64', + 'docker push grafana/fluentd:2.9-amd64', 'docker push -a grafana/fluentd', 'docker manifest create grafana/fluentd:2.9.4 grafana/fluentd:2.9.4-amd64', 'docker manifest push grafana/fluentd:2.9.4', 'docker manifest create grafana/fluentd:latest grafana/fluentd:latest-amd64', 'docker manifest push grafana/fluentd:latest', - 'docker manifest create grafana/fluentd:v2 grafana/fluentd:v2-amd64', - 'docker manifest push grafana/fluentd:v2', - 'docker manifest create grafana/fluentd:v2.9 grafana/fluentd:v2.9-amd64', - 'docker manifest push grafana/fluentd:v2.9', + 'docker manifest create grafana/fluentd:2 grafana/fluentd:2-amd64', + 'docker manifest push grafana/fluentd:2', + 'docker manifest create grafana/fluentd:2.9 grafana/fluentd:2.9-amd64', + 'docker manifest push grafana/fluentd:2.9', 'docker load -i /images/logcli-2.9.4-linux-amd64.tar', 'docker tag grafana/logcli:2.9.4-amd64 grafana/logcli:latest-amd64', 'docker push grafana/logcli:latest-amd64', - 'docker tag grafana/logcli:2.9.4-amd64 grafana/logcli:v2-amd64', - 'docker push grafana/logcli:v2-amd64', - 'docker tag grafana/logcli:2.9.4-amd64 grafana/logcli:v2.9-amd64', - 'docker push grafana/logcli:v2.9-amd64', + 'docker tag grafana/logcli:2.9.4-amd64 grafana/logcli:2-amd64', + 'docker push grafana/logcli:2-amd64', + 'docker tag grafana/logcli:2.9.4-amd64 grafana/logcli:2.9-amd64', + 'docker push grafana/logcli:2.9-amd64', 'docker load -i /images/logcli-2.9.4-linux-arm.tar', 'docker tag grafana/logcli:2.9.4-arm grafana/logcli:latest-arm', 'docker push grafana/logcli:latest-arm', - 'docker tag grafana/logcli:2.9.4-arm grafana/logcli:v2-arm', - 'docker push grafana/logcli:v2-arm', - 'docker tag grafana/logcli:2.9.4-arm grafana/logcli:v2.9-arm', - 'docker push grafana/logcli:v2.9-arm', + 'docker tag grafana/logcli:2.9.4-arm grafana/logcli:2-arm', + 'docker push grafana/logcli:2-arm', + 'docker tag grafana/logcli:2.9.4-arm grafana/logcli:2.9-arm', + 'docker push grafana/logcli:2.9-arm', 'docker load -i /images/logcli-2.9.4-linux-arm64.tar', 'docker tag grafana/logcli:2.9.4-arm64 grafana/logcli:latest-arm64', 'docker push grafana/logcli:latest-arm64', - 'docker tag grafana/logcli:2.9.4-arm64 grafana/logcli:v2-arm64', - 'docker push grafana/logcli:v2-arm64', - 'docker tag grafana/logcli:2.9.4-arm64 grafana/logcli:v2.9-arm64', - 'docker push grafana/logcli:v2.9-arm64', + 'docker tag grafana/logcli:2.9.4-arm64 grafana/logcli:2-arm64', + 'docker push grafana/logcli:2-arm64', + 'docker tag grafana/logcli:2.9.4-arm64 grafana/logcli:2.9-arm64', + 'docker push grafana/logcli:2.9-arm64', 'docker push -a grafana/logcli', 'docker manifest create grafana/logcli:2.9.4 grafana/logcli:2.9.4-amd64 grafana/logcli:2.9.4-arm grafana/logcli:2.9.4-arm64', 'docker manifest push grafana/logcli:2.9.4', 'docker manifest create grafana/logcli:latest grafana/logcli:latest-amd64 grafana/logcli:latest-arm grafana/logcli:latest-arm64', 'docker manifest push grafana/logcli:latest', - 'docker manifest create grafana/logcli:v2 grafana/logcli:v2-amd64 grafana/logcli:v2-arm grafana/logcli:v2-arm64', - 'docker manifest push grafana/logcli:v2', - 'docker manifest create grafana/logcli:v2.9 grafana/logcli:v2.9-amd64 grafana/logcli:v2.9-arm grafana/logcli:v2.9-arm64', - 'docker manifest push grafana/logcli:v2.9', + 'docker manifest create grafana/logcli:2 grafana/logcli:2-amd64 grafana/logcli:2-arm grafana/logcli:2-arm64', + 'docker manifest push grafana/logcli:2', + 'docker manifest create grafana/logcli:2.9 grafana/logcli:2.9-amd64 grafana/logcli:2.9-arm grafana/logcli:2.9-arm64', + 'docker manifest push grafana/logcli:2.9', 'docker load -i /images/logstash-2.9.4-linux-amd64.tar', 'docker tag grafana/logstash:2.9.4-amd64 grafana/logstash:latest-amd64', 'docker push grafana/logstash:latest-amd64', - 'docker tag grafana/logstash:2.9.4-amd64 grafana/logstash:v2-amd64', - 'docker push grafana/logstash:v2-amd64', - 'docker tag grafana/logstash:2.9.4-amd64 grafana/logstash:v2.9-amd64', - 'docker push grafana/logstash:v2.9-amd64', + 'docker tag grafana/logstash:2.9.4-amd64 grafana/logstash:2-amd64', + 'docker push grafana/logstash:2-amd64', + 'docker tag grafana/logstash:2.9.4-amd64 grafana/logstash:2.9-amd64', + 'docker push grafana/logstash:2.9-amd64', 'docker push -a grafana/logstash', 'docker manifest create grafana/logstash:2.9.4 grafana/logstash:2.9.4-amd64', 'docker manifest push grafana/logstash:2.9.4', 'docker manifest create grafana/logstash:latest grafana/logstash:latest-amd64', 'docker manifest push grafana/logstash:latest', - 'docker manifest create grafana/logstash:v2 grafana/logstash:v2-amd64', - 'docker manifest push grafana/logstash:v2', - 'docker manifest create grafana/logstash:v2.9 grafana/logstash:v2.9-amd64', - 'docker manifest push grafana/logstash:v2.9', + 'docker manifest create grafana/logstash:2 grafana/logstash:2-amd64', + 'docker manifest push grafana/logstash:2', + 'docker manifest create grafana/logstash:2.9 grafana/logstash:2.9-amd64', + 'docker manifest push grafana/logstash:2.9', 'docker load -i /images/loki-2.9.4-linux-amd64.tar', 'docker tag grafana/loki:2.9.4-amd64 grafana/loki:latest-amd64', 'docker push grafana/loki:latest-amd64', - 'docker tag grafana/loki:2.9.4-amd64 grafana/loki:v2-amd64', - 'docker push grafana/loki:v2-amd64', - 'docker tag grafana/loki:2.9.4-amd64 grafana/loki:v2.9-amd64', - 'docker push grafana/loki:v2.9-amd64', + 'docker tag grafana/loki:2.9.4-amd64 grafana/loki:2-amd64', + 'docker push grafana/loki:2-amd64', + 'docker tag grafana/loki:2.9.4-amd64 grafana/loki:2.9-amd64', + 'docker push grafana/loki:2.9-amd64', 'docker load -i /images/loki-2.9.4-linux-arm.tar', 'docker tag grafana/loki:2.9.4-arm grafana/loki:latest-arm', 'docker push grafana/loki:latest-arm', - 'docker tag grafana/loki:2.9.4-arm grafana/loki:v2-arm', - 'docker push grafana/loki:v2-arm', - 'docker tag grafana/loki:2.9.4-arm grafana/loki:v2.9-arm', - 'docker push grafana/loki:v2.9-arm', + 'docker tag grafana/loki:2.9.4-arm grafana/loki:2-arm', + 'docker push grafana/loki:2-arm', + 'docker tag grafana/loki:2.9.4-arm grafana/loki:2.9-arm', + 'docker push grafana/loki:2.9-arm', 'docker load -i /images/loki-2.9.4-linux-arm64.tar', 'docker tag grafana/loki:2.9.4-arm64 grafana/loki:latest-arm64', 'docker push grafana/loki:latest-arm64', - 'docker tag grafana/loki:2.9.4-arm64 grafana/loki:v2-arm64', - 'docker push grafana/loki:v2-arm64', - 'docker tag grafana/loki:2.9.4-arm64 grafana/loki:v2.9-arm64', - 'docker push grafana/loki:v2.9-arm64', + 'docker tag grafana/loki:2.9.4-arm64 grafana/loki:2-arm64', + 'docker push grafana/loki:2-arm64', + 'docker tag grafana/loki:2.9.4-arm64 grafana/loki:2.9-arm64', + 'docker push grafana/loki:2.9-arm64', 'docker push -a grafana/loki', 'docker manifest create grafana/loki:2.9.4 grafana/loki:2.9.4-amd64 grafana/loki:2.9.4-arm grafana/loki:2.9.4-arm64', 'docker manifest push grafana/loki:2.9.4', 'docker manifest create grafana/loki:latest grafana/loki:latest-amd64 grafana/loki:latest-arm grafana/loki:latest-arm64', 'docker manifest push grafana/loki:latest', - 'docker manifest create grafana/loki:v2 grafana/loki:v2-amd64 grafana/loki:v2-arm grafana/loki:v2-arm64', - 'docker manifest push grafana/loki:v2', - 'docker manifest create grafana/loki:v2.9 grafana/loki:v2.9-amd64 grafana/loki:v2.9-arm grafana/loki:v2.9-arm64', - 'docker manifest push grafana/loki:v2.9', + 'docker manifest create grafana/loki:2 grafana/loki:2-amd64 grafana/loki:2-arm grafana/loki:2-arm64', + 'docker manifest push grafana/loki:2', + 'docker manifest create grafana/loki:2.9 grafana/loki:2.9-amd64 grafana/loki:2.9-arm grafana/loki:2.9-arm64', + 'docker manifest push grafana/loki:2.9', 'docker load -i /images/loki-canary-2.9.4-linux-amd64.tar', 'docker tag grafana/loki-canary:2.9.4-amd64 grafana/loki-canary:latest-amd64', 'docker push grafana/loki-canary:latest-amd64', - 'docker tag grafana/loki-canary:2.9.4-amd64 grafana/loki-canary:v2-amd64', - 'docker push grafana/loki-canary:v2-amd64', - 'docker tag grafana/loki-canary:2.9.4-amd64 grafana/loki-canary:v2.9-amd64', - 'docker push grafana/loki-canary:v2.9-amd64', + 'docker tag grafana/loki-canary:2.9.4-amd64 grafana/loki-canary:2-amd64', + 'docker push grafana/loki-canary:2-amd64', + 'docker tag grafana/loki-canary:2.9.4-amd64 grafana/loki-canary:2.9-amd64', + 'docker push grafana/loki-canary:2.9-amd64', 'docker load -i /images/loki-canary-2.9.4-linux-arm.tar', 'docker tag grafana/loki-canary:2.9.4-arm grafana/loki-canary:latest-arm', 'docker push grafana/loki-canary:latest-arm', - 'docker tag grafana/loki-canary:2.9.4-arm grafana/loki-canary:v2-arm', - 'docker push grafana/loki-canary:v2-arm', - 'docker tag grafana/loki-canary:2.9.4-arm grafana/loki-canary:v2.9-arm', - 'docker push grafana/loki-canary:v2.9-arm', + 'docker tag grafana/loki-canary:2.9.4-arm grafana/loki-canary:2-arm', + 'docker push grafana/loki-canary:2-arm', + 'docker tag grafana/loki-canary:2.9.4-arm grafana/loki-canary:2.9-arm', + 'docker push grafana/loki-canary:2.9-arm', 'docker load -i /images/loki-canary-2.9.4-linux-arm64.tar', 'docker tag grafana/loki-canary:2.9.4-arm64 grafana/loki-canary:latest-arm64', 'docker push grafana/loki-canary:latest-arm64', - 'docker tag grafana/loki-canary:2.9.4-arm64 grafana/loki-canary:v2-arm64', - 'docker push grafana/loki-canary:v2-arm64', - 'docker tag grafana/loki-canary:2.9.4-arm64 grafana/loki-canary:v2.9-arm64', - 'docker push grafana/loki-canary:v2.9-arm64', + 'docker tag grafana/loki-canary:2.9.4-arm64 grafana/loki-canary:2-arm64', + 'docker push grafana/loki-canary:2-arm64', + 'docker tag grafana/loki-canary:2.9.4-arm64 grafana/loki-canary:2.9-arm64', + 'docker push grafana/loki-canary:2.9-arm64', 'docker push -a grafana/loki-canary', 'docker manifest create grafana/loki-canary:2.9.4 grafana/loki-canary:2.9.4-amd64 grafana/loki-canary:2.9.4-arm grafana/loki-canary:2.9.4-arm64', 'docker manifest push grafana/loki-canary:2.9.4', 'docker manifest create grafana/loki-canary:latest grafana/loki-canary:latest-amd64 grafana/loki-canary:latest-arm grafana/loki-canary:latest-arm64', 'docker manifest push grafana/loki-canary:latest', - 'docker manifest create grafana/loki-canary:v2 grafana/loki-canary:v2-amd64 grafana/loki-canary:v2-arm grafana/loki-canary:v2-arm64', - 'docker manifest push grafana/loki-canary:v2', - 'docker manifest create grafana/loki-canary:v2.9 grafana/loki-canary:v2.9-amd64 grafana/loki-canary:v2.9-arm grafana/loki-canary:v2.9-arm64', - 'docker manifest push grafana/loki-canary:v2.9' + 'docker manifest create grafana/loki-canary:2 grafana/loki-canary:2-amd64 grafana/loki-canary:2-arm grafana/loki-canary:2-arm64', + 'docker manifest push grafana/loki-canary:2', + 'docker manifest create grafana/loki-canary:2.9 grafana/loki-canary:2.9-amd64 grafana/loki-canary:2.9-arm grafana/loki-canary:2.9-arm64', + 'docker manifest push grafana/loki-canary:2.9' ]) }) @@ -301,15 +301,17 @@ describe('buildCommands', () => { `tar -x -C "/build/dir/rootfs" -f "/plugins/loki-docker-driver-2.9.4-linux-amd64.tar"`, `docker plugin create grafana/loki-docker-driver:2.9.4-amd64 "/build/dir"`, `docker plugin push "grafana/loki-docker-driver:2.9.4-amd64"`, - `docker plugin create grafana/loki-docker-driver:latest-amd64 "/build/dir"`, `docker plugin push "grafana/loki-docker-driver:latest-amd64"`, + `docker plugin push "grafana/loki-docker-driver:2.9-amd64"`, + `docker plugin push "grafana/loki-docker-driver:2-amd64"`, `rm -rf "/build/dir/rootfs" || true`, `mkdir -p "/build/dir/rootfs"`, `tar -x -C "/build/dir/rootfs" -f "/plugins/loki-docker-driver-2.9.4-linux-arm64.tar"`, `docker plugin create grafana/loki-docker-driver:2.9.4-arm64 "/build/dir"`, `docker plugin push "grafana/loki-docker-driver:2.9.4-arm64"`, - `docker plugin create grafana/loki-docker-driver:latest-arm64 "/build/dir"`, - `docker plugin push "grafana/loki-docker-driver:latest-arm64"` + `docker plugin push "grafana/loki-docker-driver:latest-arm64"`, + `docker plugin push "grafana/loki-docker-driver:2.9-arm64"`, + `docker plugin push "grafana/loki-docker-driver:2-arm64"` ] for (const command of expected) { diff --git a/actions/push-images/dist/index.js b/actions/push-images/dist/index.js index 0b335ed8..cbf594a9 100644 --- a/actions/push-images/dist/index.js +++ b/actions/push-images/dist/index.js @@ -24973,11 +24973,15 @@ function buildDockerPluginCommands(repo, buildDir, imageDir, files, isLatest) { commands.push(`docker plugin push "${repo}/${image}:${version.toString()}-${shortPlatform}"`); // Add latest tag for each platform if this is the latest version if (isLatest) { - commands.push(`docker plugin create ${repo}/${image}:latest-${shortPlatform} "${buildDir}"`, `docker plugin push "${repo}/${image}:latest-${shortPlatform}"`, - // Add major version tag (e.g., v2-amd64) - `docker plugin create ${repo}/${image}:v${version.major}-${shortPlatform} "${buildDir}"`, `docker plugin push "${repo}/${image}:v${version.major}-${shortPlatform}"`, - // Add major.minor version tag (e.g., v2.9-amd64) - `docker plugin create ${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform} "${buildDir}"`, `docker plugin push "${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform}"`); + commands.push( + //`docker plugin create ${repo}/${image}:latest-${shortPlatform} "${buildDir}"`, + `docker plugin push "${repo}/${image}:latest-${shortPlatform}"`, + // Add major version tag (e.g., 2-amd64) + //`docker plugin create ${repo}/${image}:${version.major}-${shortPlatform} "${buildDir}"`, + `docker plugin push "${repo}/${image}:${version.major}-${shortPlatform}"`, + // Add major.minor version tag (e.g., 2.9-amd64) + //`docker plugin create ${repo}/${image}:${version.major}.${version.minor}-${shortPlatform} "${buildDir}"`, + `docker plugin push "${repo}/${image}:${version.major}.${version.minor}-${shortPlatform}"`); } } } @@ -25021,19 +25025,19 @@ function buildCommands(repo, imageDir, files, isLatest) { // Add latest tag for each platform if this is the latest version if (isLatest) { commands.push(`docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:latest-${shortPlatform}`, `docker push ${repo}/${image}:latest-${shortPlatform}`, - // Add major version tag (e.g., v2-amd64) - `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:v${version.major}-${shortPlatform}`, `docker push ${repo}/${image}:v${version.major}-${shortPlatform}`, - // Add major.minor version tag (e.g., v2.9-amd64) - `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform}`, `docker push ${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform}`); + // Add major version tag (e.g., 2-amd64) + `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:${version.major}-${shortPlatform}`, `docker push ${repo}/${image}:${version.major}-${shortPlatform}`, + // Add major.minor version tag (e.g., 2.9-amd64) + `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:${version.major}.${version.minor}-${shortPlatform}`, `docker push ${repo}/${image}:${version.major}.${version.minor}-${shortPlatform}`); } } commands.push(`docker push -a ${repo}/${image}`, `docker manifest create ${repo}/${image}:${version.toString()} ${manifests.join(' ')}`, `docker manifest push ${repo}/${image}:${version.toString()}`); // Create and push latest manifest if this is the latest version if (isLatest) { const latestManifests = manifests.map(m => m.replace(`:${version.toString()}-`, ':latest-')); - const majorManifests = manifests.map(m => m.replace(`:${version.toString()}-`, `:v${version.major}-`)); - const majorMinorManifests = manifests.map(m => m.replace(`:${version.toString()}-`, `:v${version.major}.${version.minor}-`)); - commands.push(`docker manifest create ${repo}/${image}:latest ${latestManifests.join(' ')}`, `docker manifest push ${repo}/${image}:latest`, `docker manifest create ${repo}/${image}:v${version.major} ${majorManifests.join(' ')}`, `docker manifest push ${repo}/${image}:v${version.major}`, `docker manifest create ${repo}/${image}:v${version.major}.${version.minor} ${majorMinorManifests.join(' ')}`, `docker manifest push ${repo}/${image}:v${version.major}.${version.minor}`); + const majorManifests = manifests.map(m => m.replace(`:${version.toString()}-`, `:${version.major}-`)); + const majorMinorManifests = manifests.map(m => m.replace(`:${version.toString()}-`, `:${version.major}.${version.minor}-`)); + commands.push(`docker manifest create ${repo}/${image}:latest ${latestManifests.join(' ')}`, `docker manifest push ${repo}/${image}:latest`, `docker manifest create ${repo}/${image}:${version.major} ${majorManifests.join(' ')}`, `docker manifest push ${repo}/${image}:${version.major}`, `docker manifest create ${repo}/${image}:${version.major}.${version.minor} ${majorMinorManifests.join(' ')}`, `docker manifest push ${repo}/${image}:${version.major}.${version.minor}`); } } return commands; diff --git a/actions/push-images/src/docker.ts b/actions/push-images/src/docker.ts index b7c2f942..aa03ef6d 100644 --- a/actions/push-images/src/docker.ts +++ b/actions/push-images/src/docker.ts @@ -58,14 +58,14 @@ export function buildDockerPluginCommands( // Add latest tag for each platform if this is the latest version if (isLatest) { commands.push( - `docker plugin create ${repo}/${image}:latest-${shortPlatform} "${buildDir}"`, + //`docker plugin create ${repo}/${image}:latest-${shortPlatform} "${buildDir}"`, `docker plugin push "${repo}/${image}:latest-${shortPlatform}"`, - // Add major version tag (e.g., v2-amd64) - `docker plugin create ${repo}/${image}:v${version.major}-${shortPlatform} "${buildDir}"`, - `docker plugin push "${repo}/${image}:v${version.major}-${shortPlatform}"`, - // Add major.minor version tag (e.g., v2.9-amd64) - `docker plugin create ${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform} "${buildDir}"`, - `docker plugin push "${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform}"` + // Add major version tag (e.g., 2-amd64) + //`docker plugin create ${repo}/${image}:${version.major}-${shortPlatform} "${buildDir}"`, + `docker plugin push "${repo}/${image}:${version.major}-${shortPlatform}"`, + // Add major.minor version tag (e.g., 2.9-amd64) + //`docker plugin create ${repo}/${image}:${version.major}.${version.minor}-${shortPlatform} "${buildDir}"`, + `docker plugin push "${repo}/${image}:${version.major}.${version.minor}-${shortPlatform}"` ) } } @@ -122,12 +122,12 @@ export function buildCommands( commands.push( `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:latest-${shortPlatform}`, `docker push ${repo}/${image}:latest-${shortPlatform}`, - // Add major version tag (e.g., v2-amd64) - `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:v${version.major}-${shortPlatform}`, - `docker push ${repo}/${image}:v${version.major}-${shortPlatform}`, - // Add major.minor version tag (e.g., v2.9-amd64) - `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform}`, - `docker push ${repo}/${image}:v${version.major}.${version.minor}-${shortPlatform}` + // Add major version tag (e.g., 2-amd64) + `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:${version.major}-${shortPlatform}`, + `docker push ${repo}/${image}:${version.major}-${shortPlatform}`, + // Add major.minor version tag (e.g., 2.9-amd64) + `docker tag ${repo}/${image}:${version.toString()}-${shortPlatform} ${repo}/${image}:${version.major}.${version.minor}-${shortPlatform}`, + `docker push ${repo}/${image}:${version.major}.${version.minor}-${shortPlatform}` ) } } @@ -144,21 +144,21 @@ export function buildCommands( m.replace(`:${version.toString()}-`, ':latest-') ) const majorManifests = manifests.map(m => - m.replace(`:${version.toString()}-`, `:v${version.major}-`) + m.replace(`:${version.toString()}-`, `:${version.major}-`) ) const majorMinorManifests = manifests.map(m => m.replace( `:${version.toString()}-`, - `:v${version.major}.${version.minor}-` + `:${version.major}.${version.minor}-` ) ) commands.push( `docker manifest create ${repo}/${image}:latest ${latestManifests.join(' ')}`, `docker manifest push ${repo}/${image}:latest`, - `docker manifest create ${repo}/${image}:v${version.major} ${majorManifests.join(' ')}`, - `docker manifest push ${repo}/${image}:v${version.major}`, - `docker manifest create ${repo}/${image}:v${version.major}.${version.minor} ${majorMinorManifests.join(' ')}`, - `docker manifest push ${repo}/${image}:v${version.major}.${version.minor}` + `docker manifest create ${repo}/${image}:${version.major} ${majorManifests.join(' ')}`, + `docker manifest push ${repo}/${image}:${version.major}`, + `docker manifest create ${repo}/${image}:${version.major}.${version.minor} ${majorMinorManifests.join(' ')}`, + `docker manifest push ${repo}/${image}:${version.major}.${version.minor}` ) } } diff --git a/cmd/loki/main.go b/cmd/loki/main.go index cab349d0..b3c163d4 100644 --- a/cmd/loki/main.go +++ b/cmd/loki/main.go @@ -10,7 +10,7 @@ func main() { uid, err := uuid.GenerateUUID() if err != nil { - fmt.Println("Error generating a UUID") + fmt.Println("Error generating UUID") } fmt.Println("This is not really Loki, just meant to look like it. Here's a UUID: ", uid) }