change tracks to flipper motor #75
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: Docker Image CI | |
on: [push, pull_request] | |
jobs: | |
build_base: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 2 | |
- name: Check if Dockerfile.base has changed | |
id: check_files | |
uses: tj-actions/changed-files@v11.7 | |
with: | |
files: | | |
Dockerfile.base | |
- name: Log in to GitHub Container Registry | |
if: steps.check_files.outputs.any_changed == 'true' | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build and push Docker image | |
if: steps.check_files.outputs.any_changed == 'true' | |
uses: docker/build-push-action@v2 | |
with: | |
context: . | |
file: ./Dockerfile.base | |
push: true | |
tags: ghcr.io/${{ github.repository }}/base:latest | |
build_markhor: | |
needs: build_base | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 2 | |
- name: Log in to GitHub Container Registry | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build and push Docker image | |
uses: docker/build-push-action@v2 | |
with: | |
context: . | |
file: ./Dockerfile.markhor | |
push: true | |
tags: ghcr.io/${{ github.repository }}/markhor:latest |