Merge branch 'main' into feature/issue-8-telefonnummer
All checks were successful
Deploy Feature Branch to Test / deploy (push) Successful in 23s
All checks were successful
Deploy Feature Branch to Test / deploy (push) Successful in 23s
This commit is contained in:
71
.gitea/workflows/deploy-test.yml
Normal file
71
.gitea/workflows/deploy-test.yml
Normal file
@@ -0,0 +1,71 @@
|
||||
name: Deploy Feature Branch to Test
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- "feature/**"
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
volumes:
|
||||
- /var/www/test/html:/deploy
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Show branch info
|
||||
run: |
|
||||
echo "=== Deploying branch: ${{ gitea.ref_name }} ==="
|
||||
echo "=== Commit: ${{ gitea.sha }} ==="
|
||||
echo "=== By: ${{ gitea.actor }} ==="
|
||||
date
|
||||
|
||||
- name: Deploy to test environment
|
||||
run: |
|
||||
echo "Syncing files to test environment..."
|
||||
apt-get update -qq && apt-get install -y -qq rsync > /dev/null 2>&1 || true
|
||||
|
||||
rsync -av --delete \
|
||||
--exclude='.git' \
|
||||
--exclude='.gitea' \
|
||||
--exclude='.husky' \
|
||||
--exclude='.prettierrc' \
|
||||
--exclude='.prettierignore' \
|
||||
--exclude='.stylelintrc.json' \
|
||||
--exclude='.htmlhintrc' \
|
||||
--exclude='.gitignore' \
|
||||
--exclude='.dockerignore' \
|
||||
--exclude='Dockerfile' \
|
||||
--exclude='nginx.conf' \
|
||||
--exclude='eslint.config.js' \
|
||||
--exclude='package.json' \
|
||||
--exclude='docker-preview.png' \
|
||||
--exclude='page-preview.png' \
|
||||
--exclude='screenshot-landingpage*' \
|
||||
--exclude='AGENTS.md' \
|
||||
--exclude='README.md' \
|
||||
./ /deploy/
|
||||
|
||||
# Set haus-schleusingen.html as index
|
||||
cp /deploy/haus-schleusingen.html /deploy/index.html 2>/dev/null || true
|
||||
|
||||
echo "✅ Deployment complete!"
|
||||
|
||||
- name: Set permissions
|
||||
run: |
|
||||
chown -R 33:33 /deploy/ 2>/dev/null || true
|
||||
chmod -R 755 /deploy/ 2>/dev/null || true
|
||||
echo "✅ Permissions set"
|
||||
|
||||
- name: Deployment summary
|
||||
run: |
|
||||
echo "=========================================="
|
||||
echo " 🚀 Deployment Summary"
|
||||
echo "=========================================="
|
||||
echo " Branch: ${{ gitea.ref_name }}"
|
||||
echo " Commit: ${{ gitea.sha }}"
|
||||
echo " Target: http://178.104.150.0/"
|
||||
echo " Time: $(date)"
|
||||
echo "=========================================="
|
||||
Reference in New Issue
Block a user