Dodal workflow za produkcijsko okolje

This commit is contained in:
Mark Poljanšek 2025-05-18 10:27:48 +02:00
parent 135cc3b4c6
commit 3d218865ef
1 changed files with 29 additions and 0 deletions

View File

@ -0,0 +1,29 @@
name: Deploy to Production Environment
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Deploy to production environment
run: |
# Ustvari ciljni direktorij, če ne obstaja
mkdir -p /home/spletnimojster-europewonder/htdocs/europewonder.si/wp-content/themes/europewonder
# Kopiraj vse datoteke iz repozitorija v ciljni direktorij
# Uporabi rsync za ohranitev datotek, ki niso v repozitoriju
rsync -av --delete \
--exclude='.git' \
--exclude='.gitea' \
--exclude='.github' \
--exclude='README.md' \
./ /home/spletnimojster-europewonder/htdocs/europewonder.si/wp-content/themes/europewonder/
echo "Theme deployed to production environment successfully!"