new: docker image workflow
All checks were successful
Build docker image / build (push) Successful in 1m37s
All checks were successful
Build docker image / build (push) Successful in 1m37s
Signed-off-by: ngn <ngn@ngn.tf>
This commit is contained in:
28
.gitea/workflows/docker.yml
Normal file
28
.gitea/workflows/docker.yml
Normal file
@ -0,0 +1,28 @@
|
||||
name: Build docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
|
||||
env:
|
||||
REGISTRY: git.matterlinux.xyz
|
||||
IMAGE: ${{gitea.repository}}
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: "https://github.com/actions/checkout@v4"
|
||||
|
||||
- name: Login to container repo
|
||||
uses: "https://github.com/docker/login-action@v1"
|
||||
with:
|
||||
registry: ${{env.REGISTRY}}
|
||||
username: ${{gitea.actor}}
|
||||
password: ${{secrets.PACKAGES_TOKEN}}
|
||||
|
||||
- name: Build image
|
||||
run: |
|
||||
docker build --tag ${{env.REGISTRY}}/${{env.IMAGE}}:latest .
|
||||
docker push ${{env.REGISTRY}}/${{env.IMAGE}}:latest
|
Reference in New Issue
Block a user