Compare commits

..
17 Commits
Author SHA1 Message Date
jpd 614d6063ec Staging Workflow 2026-10-01 17:27:42 +01:00
jpd 728b7a9f97 Manual Action: Stop Staging 2026-10-01 17:18:18 +01:00
jpd 59652c0341 Manual Action: Start Staging 2026-10-01 17:15:33 +01:00
jpd c9301f5b92 workflow: add manual staging teardown 2026-10-01 17:06:18 +01:00
jpd 5a220c0f9b workflow: add manual staging deployment 2026-10-01 17:05:28 +01:00
jpd 1feb154cba Test and Stage Manual 2026-10-01 16:59:27 +01:00
jpd f373041ca4 Stop Staging Environment 2026-10-01 16:56:52 +01:00
jpd dbbbb66a36 Test and Stage Manual 2026-10-01 16:54:38 +01:00
jpd 94a548ec42 Stop Staging Environment 2026-10-01 16:54:12 +01:00
jpd 239d644e00 Test and Stage Pull Request 2026-10-01 16:53:37 +01:00
jpd fbba4c9e3c Cleanup Staging on Merge 2026-10-01 16:52:53 +01:00
jpd 9075071157 Stop staging manually 2026-10-01 16:48:59 +01:00
jpd 56b616d789 revert e6e8f4dcb1
revert Add .gitea/workflows/stop-staging.yml
2026-10-01 16:35:55 +01:00
jpd e6e8f4dcb1 Add .gitea/workflows/stop-staging.yml 2026-10-01 16:30:02 +01:00
jpd 61a0fde869 Add .gitea/workflows/test.yml 2026-10-01 16:29:20 +01:00
jpd 460700bf8c Update .gitea/workflows/cleanup-pr.yml 2026-10-01 00:14:10 +01:00
jpd b108bb26b8 Update .gitea/workflows/stage-pr.yml 2026-10-01 00:13:11 +01:00
4 changed files with 67 additions and 13 deletions

No files matched your search

+14
View File
@@ -0,0 +1,14 @@
name: Cleanup Staging on Merge
on:
pull_request:
types: [closed]
jobs:
cleanup:
runs-on: ubuntu-latest
steps:
- name: Stop Staging Container
run: |
docker rm -f fbird-staging || true
echo "Staging container stopped"
@@ -1,15 +1,12 @@
name: fbird CI name: Test and Stage Pull Request
on: on:
push:
branches: [ "main", "master" ]
pull_request: pull_request:
branches: [ "main", "master" ] types: [opened, synchronize, reopened]
jobs: jobs:
build-and-test: stage:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout Code - name: Checkout Code
uses: actions/checkout@v4 uses: actions/checkout@v4
+5 -7
View File
@@ -1,16 +1,14 @@
name: Stop Staging Environment name: "Staging: Stop / Teardown"
# Allows you to trigger this manually from the Gitea UI
on: on:
workflow_dispatch: workflow_dispatch:
jobs: jobs:
stop-staging: stop:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Stop and Remove Staging Container - name: Stop and Remove Staging Container
run: | run: |
echo "Tearing down staging container..." echo "Stopping staging environment..."
docker rm -f fbird-staging || true docker rm -f fbird-staging || echo "Container fbird-staging was not running."
echo "Staging environment stopped successfully!" echo "Staging environment stopped successfully."
+45
View File
@@ -0,0 +1,45 @@
name: "Staging: Start / Deploy"
on:
workflow_dispatch:
inputs:
environment:
description: 'Target environment'
required: false
default: 'staging'
type: string
jobs:
stage:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Verify Project Structure
run: |
echo "Checking repository files..."
ls -la
if [ ! -f "index.html" ] && [ ! -f "fbird.html" ]; then
echo "Error: Web HTML file missing!"
exit 1
fi
echo "Project structure verified successfully."
- name: Deploy Staging Preview
run: |
echo "Updating staging environment..."
# 1. Remove old staging container if it exists
docker rm -f fbird-staging || true
# 2. Start fresh Nginx container
docker run -d \
--name fbird-staging \
--restart always \
-p 8181:80 \
nginx:alpine
# 3. Copy repo contents directly into the Nginx web root
docker cp . fbird-staging:/usr/share/nginx/html/
echo "Staging deployed! Visit http://192.168.183.100:8181"