2020-07-31 13:17:14 -05:00
|
|
|
name: Build docker image
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- develop
|
|
|
|
tags:
|
2020-07-31 13:24:44 -05:00
|
|
|
- 'v*'
|
2020-07-31 13:17:14 -05:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
2022-08-01 10:13:34 -05:00
|
|
|
runs-on: ubuntu-22.04
|
2020-07-31 13:17:14 -05:00
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
2022-08-13 03:19:38 -05:00
|
|
|
uses: actions/checkout@v3
|
2020-11-10 12:03:14 -06:00
|
|
|
- name: Set up QEMU
|
2022-08-14 10:05:13 -05:00
|
|
|
uses: docker/setup-qemu-action@v2
|
2020-11-10 12:03:14 -06:00
|
|
|
- name: Set up Docker Buildx
|
2022-08-14 10:05:13 -05:00
|
|
|
uses: docker/setup-buildx-action@v2
|
2020-11-10 12:06:50 -06:00
|
|
|
with:
|
2020-11-10 12:03:14 -06:00
|
|
|
version: latest
|
2020-07-31 13:37:14 -05:00
|
|
|
- name: Login to docker hub
|
2022-08-14 10:05:13 -05:00
|
|
|
uses: docker/login-action@v2
|
2020-11-10 12:03:14 -06:00
|
|
|
with:
|
|
|
|
username: ${{ secrets.DOCKER_USERNAME }}
|
|
|
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
2022-08-14 10:05:13 -05:00
|
|
|
- name: Login to GitHub container registry
|
|
|
|
uses: docker/login-action@v2
|
|
|
|
with:
|
|
|
|
registry: ghcr.io
|
|
|
|
username: ${{ github.repository_owner }}
|
|
|
|
password: ${{ secrets.GHCR_PAT }}
|
|
|
|
- name: Build and push the image
|
2020-07-31 13:17:14 -05:00
|
|
|
run: bash ./docker/build
|