Just build amd64 #43
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | ||
name: "Build" | ||
on: | ||
pull_request: | ||
jobs: | ||
build: | ||
name: "Build Docker image and push to Dockerhub" | ||
runs-on: ubuntu-latest | ||
env: | ||
AWS_REGION: eu-west-1 | ||
# These permissions are needed to interact with GitHub's OIDC Token endpoint. | ||
permissions: | ||
id-token: write | ||
contents: read | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Configure AWS Credentials | ||
uses: aws-actions/configure-aws-credentials@v4 | ||
with: | ||
role-to-assume: arn:aws:iam::118330671040:role/node-indexer-ci | ||
aws-region: ${{ env.AWS_REGION }} | ||
- name: Login to Amazon ECR | ||
id: login-ecr | ||
uses: aws-actions/amazon-ecr-login@v2 | ||
- name: Install prerequisites for Docker build | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y qemu-user-static | ||
- env: | ||
GITHUB_TOKEN: ${{ secrets.DUNE_ENG_ACCESS_TOKEN }} | ||
DOCKER_HUB_KEY: ${{ secrets.DOCKER_HUB_KEY }} | ||
run: | | ||
# docker buildx create --name mybuilder | ||
# docker buildx use mybuilder | ||
docker buildx build --platform linux/amd64 -t public.ecr.aws/duneanalytics/node-indexer:latest -f Dockerfile --build-arg GITHUB_TOKEN=${GITHUB_TOKEN} --push . |