update action
This commit is contained in:
parent
75bd4f49c1
commit
260ee0b44f
2 changed files with 35 additions and 25 deletions
35
.forgejo/workflows/build.yml
Normal file
35
.forgejo/workflows/build.yml
Normal file
|
@ -0,0 +1,35 @@
|
|||
name: deploy
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: host
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v3
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
registry: git.hydrar.de
|
||||
username: ${{ secrets.registry_user }}
|
||||
password: ${{ secrets.registry_password }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@v4
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/amd64,linux/arm64
|
||||
push: true
|
||||
tags: git.hydrar.de/jmarya/hoard:latest
|
|
@ -1,25 +0,0 @@
|
|||
name: build
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Install Docker
|
||||
run: curl -fsSL https://get.docker.com | sh
|
||||
|
||||
- name: Log in to Docker registry
|
||||
run: echo "${{ secrets.registry_password }}" | docker login -u "${{ secrets.registry_user }}" --password-stdin git.hydrar.de
|
||||
|
||||
- name: Build and push Docker image
|
||||
run: |
|
||||
docker build -t git.hydrar.de/jmarya/hoard:latest .
|
||||
docker push git.hydrar.de/jmarya/hoard:latest
|
Loading…
Reference in a new issue