Skip to content

add signing commits to workflow (#22) #46

add signing commits to workflow (#22)

add signing commits to workflow (#22) #46

name: Build and deploy
on:
workflow_dispatch:
push:
paths-ignore:
- '*.md'
branches:
- master
jobs:
build_and_push_processor:
name: Build and push Processor
runs-on: ubuntu-20.04
steps:
- name: GIT | Checkout
uses: actions/checkout@v4
- name: DOCKER | Build and push squid-processor image
uses: ./.github/actions/build-and-push
id: build_processor
with:
registry: squid-processor
target: processor
aws_mainnet_access_key_id: ${{ secrets.AWS_MAINNET_ACCESS_KEY_ID }}
aws_mainnet_secret_access_key: ${{ secrets.AWS_MAINNET_SECRET_ACCESS_KEY }}
aws_devnet_access_key_id: ${{ secrets.AWS_DEVNET_ACCESS_KEY_ID }}
aws_devnet_secret_access_key: ${{ secrets.AWS_DEVNET_SECRET_ACCESS_KEY }}
outputs:
image_tag: ${{ steps.build_processor.outputs.image_tag }}
build_and_push_api:
name: Build and push API
runs-on: ubuntu-20.04
steps:
- name: GIT | Checkout
uses: actions/checkout@v4
- name: DOCKER | Build and push squid-api image
uses: ./.github/actions/build-and-push
id: build_api
with:
registry: squid-api
target: query-node
aws_mainnet_access_key_id: ${{ secrets.AWS_MAINNET_ACCESS_KEY_ID }}
aws_mainnet_secret_access_key: ${{ secrets.AWS_MAINNET_SECRET_ACCESS_KEY }}
aws_devnet_access_key_id: ${{ secrets.AWS_DEVNET_ACCESS_KEY_ID }}
aws_devnet_secret_access_key: ${{ secrets.AWS_DEVNET_SECRET_ACCESS_KEY }}
outputs:
image_tag: ${{ steps.build_api.outputs.image_tag }}
deploy_processor:
name: Deploy Processor
needs: build_and_push_processor
runs-on: ubuntu-20.04
steps:
- name: GIT | Checkout
uses: actions/checkout@v4
- name: DEVNET | Deploy squid-process image to devnet
uses: ./.github/actions/deploy-to-devnet
with:
registry: squid-processor
image_tag: ${{ needs.build_and_push_processor.outputs.image_tag }}
aws_devnet_access_key_id: ${{ secrets.AWS_DEVNET_ACCESS_KEY_ID }}
aws_devnet_secret_access_key: ${{ secrets.AWS_DEVNET_SECRET_ACCESS_KEY }}
github_token: ${{ secrets.CI_GH_TOKEN }}
kustomize_version: ${{ vars.KUSTOMIZE_VERSION }}
autocommit-author: ${{ secrets.AUTOCOMMIT_AUTHOR }}
autocommit-email: ${{ secrets.AUTOCOMMIT_EMAIL }}
autocommit-gpg-key-b64: ${{ secrets.AUTOCOMMIT_GPG_KEY_B64 }}
autocommit-gpg-key-fingerprint: ${{ secrets.AUTOCOMMIT_GPG_KEY_FINGERPRINT }}
deploy_api:
name: Deploy API
needs: [build_and_push_api, deploy_processor]
runs-on: ubuntu-20.04
steps:
- name: GIT | Checkout
uses: actions/checkout@v4
- name: DEVNET | Deploy squid-api image to devnet
uses: ./.github/actions/deploy-to-devnet
with:
registry: squid-api
image_tag: ${{ needs.build_and_push_api.outputs.image_tag }}
aws_devnet_access_key_id: ${{ secrets.AWS_DEVNET_ACCESS_KEY_ID }}
aws_devnet_secret_access_key: ${{ secrets.AWS_DEVNET_SECRET_ACCESS_KEY }}
github_token: ${{ secrets.CI_GH_TOKEN }}
kustomize_version: ${{ vars.KUSTOMIZE_VERSION }}