Skip to content

Commit 2d3ffdf

Browse files
authored
Add labels output to Docker build and push step
1 parent 004786e commit 2d3ffdf

1 file changed

Lines changed: 41 additions & 1 deletion

File tree

.github/workflows/Prebuild.yaml

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,44 @@ jobs:
4949
push: ${{ github.event_name != 'pull_request' }}
5050
platforms: linux/arm64
5151
tags: ${{ steps.meta.outputs.tags }}
52-
labels: ${{ steps.meta.outputs.labels }}
52+
labels: ${{ steps.meta.outputs.labels }}
53+
development:
54+
name: 'Development'
55+
runs-on: ubuntu-24.04-arm
56+
steps:
57+
- name: Checkout code
58+
uses: actions/checkout@v3
59+
60+
- name: Configure AWS credentials (OIDC)
61+
uses: aws-actions/configure-aws-credentials@v4
62+
with:
63+
role-to-assume: arn:aws:iam::300197899440:role/ECRPrebuildPushRightsForGithubActionsRole
64+
aws-region: us-east-1
65+
66+
- name: Login to Amazon ECR Public
67+
id: login-ecr-public
68+
uses: aws-actions/amazon-ecr-login@v2
69+
with:
70+
registry-type: public
71+
72+
- name: Docker meta
73+
id: meta
74+
uses: docker/metadata-action@v4
75+
with:
76+
images: ${{ env.REGISTRY }}/${{ env.PROJECT }}
77+
tags: |
78+
type=ref,event=branch
79+
type=ref,event=tag
80+
# Set latest tag for default branch
81+
type=raw,value=latest,enable={{is_default_branch}}
82+
flavor: |
83+
suffix=-dev.,onlatest=true
84+
85+
- name: Build and push
86+
uses: docker/build-push-action@v6
87+
with:
88+
file: Dockerfile.dev
89+
push: ${{ github.event_name != 'pull_request' }}
90+
platforms: linux/arm64
91+
tags: ${{ steps.meta.outputs.tags }}
92+
labels: ${{ steps.meta.outputs.labels }}

0 commit comments

Comments
 (0)