Skip to content

eksctl 0.207.0

eksctl 0.207.0 #115

Workflow file for this run

name: Publish ECR image
on:
release:
types: [published]
permissions:
id-token: write
contents: read
jobs:
build-and-push-to-registry:
name: Build and push container image
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@ececac1a45f3b08a01d2dd070d28d111c5fe6722 # v4.1.0
with:
aws-region: us-east-1
role-duration-seconds: 7200
role-session-name: eksctl-ecr-publisher
role-to-assume: ${{ secrets.ECR_PUBLISH_ROLE_ARN }}
- name: Login to Amazon ECR Public
id: login-ecr-public
uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 # v2.0.1
with:
registry-type: public
- name: Extract metadata (tags, labels)
id: meta
uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 #5.7.0
env:
REGISTRY: ${{ steps.login-ecr-public.outputs.registry }}
REGISTRY_ALIAS: eksctl
REPOSITORY: eksctl
with:
images: ${{ env.REGISTRY }}/${{ env.REGISTRY_ALIAS }}/${{ env.REPOSITORY }}
- name: Build and push container image to ECR
uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 #6.15.0
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}