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
This commit is contained in:
2025-12-02 17:49:08 +08:00
parent 58ea6a0e11
commit 7e4270a36e
10 changed files with 3159 additions and 0 deletions

View File

@@ -0,0 +1,34 @@
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 }}'