Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
perekopskiy committed May 17, 2024
1 parent cc9351b commit 484086f
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 3 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/release-stable-en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ on:
description: "Tag of an image"
type: string
required: true
push:
branches:
- fix-release-stable-en

jobs:
release:
Expand All @@ -18,19 +21,19 @@ jobs:
- name: Check if alpha image exists
run: |
set +e
docker manifest inspect matterlabs/external-node:${{ inputs.tag_name }}-alpha >/dev/null 2>&1
docker manifest inspect matterlabs/external-node:v24.2.0-alpha >/dev/null 2>&1
exitcode=$?
set -e
if [[ "$exitcode" -eq "1" ]]; then
echo "Image matterlabs/external-node:${{ inputs.tag_name }} doesn't exist"
echo "Image matterlabs/external-node:${{ inputs.tag_name }}-alpha doesn't exist"
exit 1
fi
- name: Push stable image
run: |
docker_repositories=("matterlabs/external-node" "us-docker.pkg.dev/matterlabs-infra/matterlabs-docker/external-node")
platforms=linux/amd64,linux/arm64
tag_name="${{ inputs.tag_name }}"
tag_name="v24.2.0"
for repo in "${docker_repositories[@]}"; do
platform_tags=""
for platform in ${platforms//,/ }; do
Expand Down
22 changes: 22 additions & 0 deletions tst.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
docker_repositories=("matterlabs/external-node" "us-docker.pkg.dev/matterlabs-infra/matterlabs-docker/external-node")
platforms=linux/amd64,linux/arm64
tag_name="v24.2.0"
for repo in "${docker_repositories[@]}"; do
platform_tags=""
for platform in ${platforms//,/ }; do
platform=$(echo $platform | tr '/' '-')
alpha_tag="${repo}:${tag_name}-alpha-${platform}"
tag="${repo}:${tag_name}-${platform}"
# docker pull $alpha_tag
# docker tag $alpha_tag $tag
# docker push $tag

platform_tags+=" --amend $tag"
done
echo $platform_tags
for manifest in "${repo}:${tag_name}" "${repo}:2.0-${tag_name}"; do
echo $manifest
# docker manifest create ${manifest} ${platform_tags}
# docker manifest push ${manifest}
done
done

0 comments on commit 484086f

Please sign in to comment.