Skip to content

Commit

Permalink
feat: split builds
Browse files Browse the repository at this point in the history
  • Loading branch information
kdurek committed Jul 17, 2024
1 parent b0b5b94 commit 14442c6
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions .github/workflows/canary.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Canary

on:
push:
branches:
- canary

jobs:
build-amd64-and-push:
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/checkout@v4

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Prepare .env file
run: |
cp .env.production.example .env.production
- name: Build image and push to registry
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile
platforms: linux/amd64
push: true
tags: canary

build-arm64-and-push:
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/checkout@v4

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Prepare .env file
run: |
cp .env.production.example .env.production
- name: Build image and push to registry
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile
platforms: linux/arm64
push: true
tags: canary

0 comments on commit 14442c6

Please sign in to comment.