mirror of
https://github.com/Smile-QWQ/SubTracker.git
synced 2026-06-20 17:25:59 +08:00
docs: improve deployment docs and release assets
- rewrite README for GitHub presentation and add env copy steps for local development - expand DEPLOYMENT guide with API-only and full compose deployment paths - add apps/api/.env.example for development bootstrap - add docker-compose.full.yml and nginx config for full self-hosted deployment - update release workflow to publish a deployment bundle alongside web dist assets
This commit is contained in:
36
.github/workflows/build-and-release.yml
vendored
36
.github/workflows/build-and-release.yml
vendored
@@ -49,6 +49,19 @@ jobs:
|
||||
cd apps/web/dist
|
||||
zip -r ../../../subtracker-web-dist.zip .
|
||||
|
||||
- name: Archive deployment bundle
|
||||
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch'
|
||||
run: |
|
||||
mkdir -p release-assets/subtracker-deploy/docker
|
||||
cp docker-compose.yml release-assets/subtracker-deploy/
|
||||
cp docker-compose.full.yml release-assets/subtracker-deploy/
|
||||
cp DEPLOYMENT.md release-assets/subtracker-deploy/
|
||||
cp README.md release-assets/subtracker-deploy/
|
||||
cp apps/api/.env.example release-assets/subtracker-deploy/api.env.example
|
||||
cp docker/nginx.full.conf release-assets/subtracker-deploy/docker/nginx.full.conf
|
||||
cd release-assets
|
||||
zip -r ../subtracker-deploy-bundle.zip subtracker-deploy
|
||||
|
||||
- name: Upload web artifact
|
||||
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch'
|
||||
uses: actions/upload-artifact@v4
|
||||
@@ -56,6 +69,13 @@ jobs:
|
||||
name: subtracker-web-dist
|
||||
path: subtracker-web-dist.zip
|
||||
|
||||
- name: Upload deployment artifact
|
||||
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch'
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: subtracker-deploy-bundle
|
||||
path: subtracker-deploy-bundle.zip
|
||||
|
||||
release:
|
||||
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch'
|
||||
runs-on: ubuntu-latest
|
||||
@@ -91,6 +111,18 @@ jobs:
|
||||
cd apps/web/dist
|
||||
zip -r ../../../subtracker-web-dist.zip .
|
||||
|
||||
- name: Archive deployment bundle
|
||||
run: |
|
||||
mkdir -p release-assets/subtracker-deploy/docker
|
||||
cp docker-compose.yml release-assets/subtracker-deploy/
|
||||
cp docker-compose.full.yml release-assets/subtracker-deploy/
|
||||
cp DEPLOYMENT.md release-assets/subtracker-deploy/
|
||||
cp README.md release-assets/subtracker-deploy/
|
||||
cp apps/api/.env.example release-assets/subtracker-deploy/api.env.example
|
||||
cp docker/nginx.full.conf release-assets/subtracker-deploy/docker/nginx.full.conf
|
||||
cd release-assets
|
||||
zip -r ../subtracker-deploy-bundle.zip subtracker-deploy
|
||||
|
||||
- name: Resolve release tag
|
||||
id: release_tag
|
||||
shell: bash
|
||||
@@ -136,5 +168,7 @@ jobs:
|
||||
with:
|
||||
tag_name: ${{ steps.release_tag.outputs.value }}
|
||||
name: ${{ steps.release_tag.outputs.value }}
|
||||
files: subtracker-web-dist.zip
|
||||
files: |
|
||||
subtracker-web-dist.zip
|
||||
subtracker-deploy-bundle.zip
|
||||
generate_release_notes: true
|
||||
|
||||
Reference in New Issue
Block a user