2024-09-20 00:33:32 -04:00
|
|
|
name: build
|
|
|
|
run-name: ${{ gitea.actor }} is building.
|
2024-09-20 00:36:31 -04:00
|
|
|
on: [push]
|
2024-09-20 00:33:32 -04:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-09-20 13:31:51 -04:00
|
|
|
- name: login to container registry
|
|
|
|
uses: docker/login-action@v3
|
|
|
|
with:
|
2024-09-20 13:41:30 -04:00
|
|
|
registry: 10.0.0.103:3000
|
2024-09-20 13:31:51 -04:00
|
|
|
username: ${{ gitea.actor }}
|
|
|
|
password: ${{ secrets.GITEA_TOKEN }}
|
|
|
|
- name: docker buildx setup
|
|
|
|
uses: docker/setup-buildx-action@v3
|
2024-09-20 13:39:41 -04:00
|
|
|
with:
|
|
|
|
config-inline: |
|
2024-09-20 13:40:44 -04:00
|
|
|
[registry."10.0.0.103:3000"]
|
2024-09-20 13:39:41 -04:00
|
|
|
http = true
|
|
|
|
insecure = true
|
2024-09-20 00:33:32 -04:00
|
|
|
- name: checkout code
|
|
|
|
uses: actions/checkout@v4
|
2024-09-20 13:31:51 -04:00
|
|
|
- name: build and push to registry
|
|
|
|
uses: docker/build-push-action@v6
|
2024-09-20 00:33:32 -04:00
|
|
|
with:
|
2024-09-20 13:39:41 -04:00
|
|
|
context: .
|
|
|
|
file: ./Dockerfile
|
|
|
|
platforms: |
|
|
|
|
linux/amd64
|
|
|
|
linux/arm64
|
2024-09-20 13:31:51 -04:00
|
|
|
push: true
|
2024-09-20 13:39:41 -04:00
|
|
|
tags: |
|
2024-09-20 13:40:44 -04:00
|
|
|
10.0.0.103:3000/${{ gitea.repository_owner }}/${{ gitea.repository }}:dev
|