Skip to content

Commit ec070f3

Browse files
authored
Add workflow for xc-admin releases (#564)
1 parent 8c57458 commit ec070f3

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Build and Push Cross Chain Admin
2+
on:
3+
push:
4+
tags:
5+
- xc-admin-v*
6+
permissions:
7+
contents: read
8+
id-token: write
9+
jobs:
10+
xc-admin-image:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Set image tag to version of the git tag
15+
if: ${{ startsWith(github.ref, 'refs/tags/xc-admin-v') }}
16+
run: |
17+
PREFIX="refs/tags/xc-admin-"
18+
VERSION="${GITHUB_REF:${#PREFIX}}"
19+
echo "IMAGE_TAG=${VERSION}" >> "${GITHUB_ENV}"
20+
- uses: aws-actions/configure-aws-credentials@8a84b07f2009032ade05a88a28750d733cc30db1
21+
with:
22+
role-to-assume: arn:aws:iam::192824654885:role/github-actions-ecr
23+
aws-region: eu-west-2
24+
- uses: docker/login-action@v2
25+
with:
26+
registry: public.ecr.aws
27+
env:
28+
AWS_REGION: us-east-1
29+
- run: |
30+
DOCKER_BUILDKIT=1 docker build -t lerna -f tilt_devnet/docker_images/Dockerfile.lerna .
31+
DOCKER_BUILDKIT=1 docker build -t $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG -f governance/xc_admin/Dockerfile .
32+
docker push $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG
33+
env:
34+
ECR_REGISTRY: public.ecr.aws
35+
ECR_REPOSITORY: pyth-network/xc-admin

0 commit comments

Comments
 (0)