From 6c770e38c5c898ad3ce51a6c2cc60e25a4009c03 Mon Sep 17 00:00:00 2001 From: Guillaume Charest <1690085+gcharest@users.noreply.github.com> Date: Thu, 18 Apr 2024 16:04:18 +0000 Subject: [PATCH] fix: update script to fetch the geodb data --- .github/workflows/ci_container.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci_container.yml b/.github/workflows/ci_container.yml index f83730e6..68c9d0c4 100644 --- a/.github/workflows/ci_container.yml +++ b/.github/workflows/ci_container.yml @@ -22,12 +22,22 @@ jobs: - name: Checkout uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 + - name: Configure aws credentials using OIDC + uses: aws-actions/configure-aws-credentials@master + with: + role-to-assume: arn:aws:iam::283582579564:role/sre-bot-apply + role-session-name: SREBotGitHubActions + aws-region: "ca-central-1" + + - name: Download GeoDB from S3 + run: | + aws s3 cp s3://${{ secrets.GEO_DB_BUCKET }}/GeoLite2-City.tar.gz ./app/geodb/GeoLite2-City.tar.gz + - name: Build container working-directory: ./ run: | docker build \ --build-arg git_sha=$GITHUB_SHA \ - --build-arg LICENSE_KEY=${{ secrets.MAXMIND_LICENSE }} \ -t sre-bot:latest \ -t $REGISTRY/sre-bot:$GITHUB_SHA-`date '+%Y-%m-%d'` \ -t $REGISTRY/sre-bot:latest . \ No newline at end of file