26 lines
828 B
YAML
26 lines
828 B
YAML
name: Build Image using Dockerfile
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build:
|
|
name: Build image
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
# https://github.com/marketplace/actions/push-to-ghcr
|
|
- name: Build and publish a Docker image for ${{ gitea.repository }}
|
|
uses: macbre/push-to-ghcr@v13
|
|
with:
|
|
image_name: ${{ gitea.repository }} # it will be lowercased internally
|
|
# github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
# optionally push to the Docker Hub (docker.io)
|
|
docker_io_token: ${{ secrets.DOCKER_IO_ACCESS_TOKEN }} # see https://hub.docker.com/settings/security
|
|
# customize the username to be used when pushing to the Docker Hub
|
|
docker_io_user: tandrade # see https://github.com/macbre/push-to-ghcr/issues/14
|