Skip to content

[os] linux/arm64 4 Raspberry PI #40

[os] linux/arm64 4 Raspberry PI

[os] linux/arm64 4 Raspberry PI #40

Workflow file for this run

name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
release:
types: [published]
jobs:
backend-build:
runs-on: ubuntu-latest
steps:
- name: Checkout backend code
uses: actions/checkout@v3
- name: Build and push the Docker image for backend
run: |
if [ ${{ github.event_name }} == 'pull_request' ]; then
DOCKER_IMAGE_TAG=development
else
DOCKER_IMAGE_TAG=production
fi
docker build ./backend -t themanwholikestocode/archive-me-prod:backend-$DOCKER_IMAGE_TAG --platform=linux/amd64
echo ${{ secrets.DOCKER_PASSWORD }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin
docker push themanwholikestocode/archive-me-prod:backend-$DOCKER_IMAGE_TAG
frontend-build:
runs-on: ubuntu-latest
steps:
- name: Checkout frontend code
uses: actions/checkout@v3
- name: Build and push the Docker image for frontend
run: |
if [ ${{ github.event_name }} == 'pull_request' ]; then
DOCKER_IMAGE_TAG=development
else
DOCKER_IMAGE_TAG=production
fi
docker build ./frontend -t themanwholikestocode/archive-me-prod:frontend-$DOCKER_IMAGE_TAG --platform=linux/amd64
echo ${{ secrets.DOCKER_PASSWORD }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin
docker push themanwholikestocode/archive-me-prod:frontend-$DOCKER_IMAGE_TAG