feature: Adds building workflows.

This commit is contained in:
Tera << 8 2024-12-24 09:52:06 -05:00
parent b0b11413fb
commit 7879c65e25
Signed by: imterah
GPG key ID: 8FA7DD57BA6CEA37
7 changed files with 33 additions and 241 deletions

View file

@ -0,0 +1,33 @@
name: Release code
on:
push:
tags:
- "**"
jobs:
build:
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- name: Checkout code using Git
uses: actions/checkout@main
- name: Log in to Forgejo container registry
uses: https://github.com/docker/login-action@v3
with:
registry: git.terah.dev
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build all docker images
run: |
docker build ./backend --tag git.terah.dev/imterah/hermes:$GITHUB_REF_NAME
- name: Upload all docker images
run: |
docker tag git.terah.dev/imterah/hermes:$GITHUB_REF_NAME git.terah.dev/imterah/hermes:latest
docker push git.terah.dev/imterah/hermes:$GITHUB_REF_NAME
docker push git.terah.dev/imterah/hermes:latest