Skip to content

Gateway: 0.1.299

Gateway: 0.1.299 #598

Workflow file for this run

name: Build and release Worker
on:
release:
types: [created]
permissions:
id-token: write
contents: read
jobs:
build_and_release_worker:
if: startsWith(github.ref, 'refs/tags/worker-')
environment: Release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: ${{ secrets.AWS_IAM_ROLE_GITHUB }}
aws-region: us-east-1
- name: Log in to Amazon ECR
uses: aws-actions/amazon-ecr-login@v2
id: login-ecr
with:
registry-type: public
mask-password: "true"
- name: Set version
id: set-version
run: |
echo "TAG_NAME=${GITHUB_REF_NAME#worker-}" >> $GITHUB_OUTPUT
- name: Build and push container image to Amazon ECR
uses: docker/build-push-action@v5
with:
file: ./docker/Dockerfile.worker
push: true
tags: |
${{ steps.login-ecr.outputs.registry }}/n4e0e1y0/beta9-worker:${{ steps.set-version.outputs.TAG_NAME }}
${{ steps.login-ecr.outputs.registry }}/n4e0e1y0/beta9-worker:latest
target: final
platforms: linux/amd64
build-args: |
CEDANA_TOKEN=${{ secrets.CEDANA_TOKEN }}
CEDANA_BASE_URL=${{ secrets.CEDANA_BASE_URL }}