Files
website-ricenoodletw-cms/.gitea/workflows/deploy.yaml
pkupuk 7e4270a36e feat(ci): add CI/CD workflow and spec workflow setup
- Add Gitea workflow for build and deploy
- Add spec workflow configuration and templates
- Update package lock file for dependencies
2025-12-02 17:49:08 +08:00

35 lines
942 B
YAML

name: Build and Deploy
run-name: ${{ gitea.actor }} is building and deploying to Coolify 🚀
on:
push:
branches:
- main
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/website-ricenoodletw-cms:latest
- name: Trigger Coolify Deployment
run: |
curl --request GET '${{ secrets.COOLIFY_WEBHOOK }}' --header 'Authorization: Bearer ${{ secrets.COOLIFY_TOKEN }}'