Skip to content

Merge pull request #77 from yasuyuky/dependabot/docker/rust-1.73.0-bu… #66

Merge pull request #77 from yasuyuky/dependabot/docker/rust-1.73.0-bu…

Merge pull request #77 from yasuyuky/dependabot/docker/rust-1.73.0-bu… #66

Workflow file for this run

name: CI
on:
push:
branches:
- main
env:
REGISTRY: ghcr.io
IMAGE_NAME: rust-arm
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
packages: write
steps:
- uses: actions/checkout@v4
- name: Commit files
id: tagging
run: |
git config --local user.email "[email protected]"
git config --local user.name "Yasuyuki YAMADA"
TAGNAME=$(grep FROM Dockerfile|cut -f 2 -d ':'|cut -f 1 -d '-')
git tag -f -a ${TAGNAME} -m "${TAGNAME} Tagged by CI"
echo tag=${TAGNAME} >>$GITHUB_OUTPUT
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: Log in to the Container registry
uses: docker/login-action@v2
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
with:
context: .
push: true
tags: |
${{ env.REGISTRY }}/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:latest
${{ env.REGISTRY }}/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:${{ steps.tagging.outputs.tag }}