Skip to content

Update Node.js to d0a9a23 (#647) #346

Update Node.js to d0a9a23 (#647)

Update Node.js to d0a9a23 (#647) #346

Workflow file for this run

name: "Build & Push"
on:
push:
branches:
- "main"
tags:
- "*"
paths:
- "packages/**"
- "!packages/*/scripts/**"
jobs:
build_push_image:
name: ${{ matrix.image_name }}
runs-on: ubuntu-latest
environment: dev
permissions:
contents: read
id-token: write
strategy:
fail-fast: false
matrix:
include:
- image_name: catalog-process
dockerfile_path: packages/catalog-process
- image_name: catalog-readmodel-writer
dockerfile_path: packages/catalog-readmodel-writer
- image_name: agreement-process
dockerfile_path: packages/agreement-process
- image_name: agreement-readmodel-writer
dockerfile_path: packages/agreement-readmodel-writer
- image_name: tenant-process
dockerfile_path: packages/tenant-process
- image_name: tenant-readmodel-writer
dockerfile_path: packages/tenant-readmodel-writer
- image_name: purpose-process
dockerfile_path: packages/purpose-process
- image_name: purpose-readmodel-writer
dockerfile_path: packages/purpose-readmodel-writer
- image_name: attribute-registry-process
dockerfile_path: packages/attribute-registry-process
- image_name: attribute-registry-readmodel-writer
dockerfile_path: packages/attribute-registry-readmodel-writer
- image_name: authorization-updater
dockerfile_path: packages/authorization-updater
- image_name: notifier-seeder
dockerfile_path: packages/notifier-seeder
- image_name: eservice-descriptors-archiver
dockerfile_path: packages/eservice-descriptors-archiver
steps:
- name: Checkout repository
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4
with:
aws-region: ${{ vars.AWS_REGION }}
role-to-assume: ${{ vars.IAM_ROLE_ARN }}
role-session-name: be-monorepo-build-push-${{ github.run_number }}
- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 # v2
- name: (latest) Docker metadata
id: meta_latest
if: ${{ github.ref_type == 'branch' }}
uses: docker/metadata-action@f7b4ed12385588c3f9bc252f0a2b520d83b52d48
with:
images: ${{ steps.login-ecr.outputs.registry }}/interop-be-${{ matrix.image_name }}
flavor: |
latest=false
prefix=
suffix=
tags: |
type=raw,value=2.x-latest
- name: (tag) Docker metadata
id: meta_tag
if: ${{ github.ref_type == 'tag' }}
uses: docker/metadata-action@f7b4ed12385588c3f9bc252f0a2b520d83b52d48
with:
images: ${{ steps.login-ecr.outputs.registry }}/interop-be-${{ matrix.image_name }}
flavor: |
latest=false
prefix=
suffix=
tags: |
type=ref,event=tag
- name: Build and push Docker image
id: build_push
uses: docker/build-push-action@cfed4e995e12d7bee5002f066f5649e5f1cc059c
with:
context: .
file: ${{ matrix.dockerfile_path }}/Dockerfile
push: true
tags: ${{ github.ref_type == 'branch' && steps.meta_latest.outputs.tags || steps.meta_tag.outputs.tags }}
labels: ${{ github.ref_type == 'branch' && steps.meta_latest.outputs.labels || steps.meta_tag.outputs.labels }}