Skip to content

chore[avas]:go program update #36

chore[avas]:go program update

chore[avas]:go program update #36

Workflow file for this run

name: avas-indexer-ECR
on:
push:
branches:
- chainbase
tags:
- "avas_*"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Get version
id: get_version
run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT
# Publish to AWS ECR
- name: Checkout repository
uses: actions/checkout@v2
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1
- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v1
- name: Build, tag, and push image to Amazon ECR
env:
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
ECR_REPOSITORY: ethereum-etl
IMAGE_TAG: ${{ steps.get_version.outputs.VERSION }}
AVAS_GO_IMAGE_TAG: avas_24012901
AVAS_GO_REPOSITORY: avas-open-indexer
run: |
echo "COPY --from=$ECR_REGISTRY/$AVAS_GO_REPOSITORY:$AVAS_GO_IMAGE_TAG /avas-open-indexer/indexer /\$PROJECT_DIR/indexer" >> avas_Dockerfile
docker build -t $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG \
-f ./avas_Dockerfile .
docker push $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG