chore(nightly): distinguish nightly build and latest build and add CI support and examples
Build Docker Image / build (push) Has been cancelled Details

This commit is contained in:
subcrip 2024-04-02 14:21:30 +08:00
parent 4cf5e64fed
commit b51e272424
Signed by: subcrip
SSH Key Fingerprint: SHA256:dFPFi68d8C87YkFkEBU4TkcrYRySWpekRR1hbnDWUCw
3 changed files with 25 additions and 3 deletions

View File

@ -0,0 +1,19 @@
name: Build Docker Image
on: [ push ]
jobs:
build:
runs-on: ubuntu20.04
steps:
- uses: actions/checkout@v4
- uses: docker/setup-buildx-action@v3
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: "arielherself/myoauth:nightly"

View File

@ -1,5 +1,8 @@
pack: pack:
sudo docker build -t myoauth . --no-cache sudo docker build -t myoauth . --no-cache
publish: publish-latest:
sudo docker tag myoauth arielherself/myoauth && sudo docker push arielherself/myoauth sudo docker tag myoauth arielherself/myoauth:latest && sudo docker push arielherself/myoauth:latest
publish-nightly:
sudo docker tag myoauth arielherself/myoauth:nightly && sudo docker push arielherself/myoauth:nightly

View File

@ -1,7 +1,7 @@
name: myoauth name: myoauth
services: services:
myoauth_core: myoauth_core:
image: arielherself/myoauth image: arielherself/myoauth:latest
container_name: myoauth_core container_name: myoauth_core
environment: environment:
POSTGRES_HOST: postgres POSTGRES_HOST: postgres