eledana/.gitea/workflows/main.yml

26 lines
752 B
YAML
Raw Normal View History

2024-11-07 19:09:57 +00:00
name: Build, push and deploy
on:
push:
branches:
- main
jobs:
builds:
runs-on: slimbook-ubuntu-latest
steps:
- name: checkout code
uses: actions/checkout@v2
2024-11-07 22:07:13 +00:00
- name: rclone to remote
run: |
ls -lha
2024-11-07 22:11:29 +00:00
printf "%s" "${{ secrets.ID_ED25519 }}" > ./id_ed25519
chmod 600 ./id_ed25519 # Set proper permissions
2024-11-07 22:46:31 +00:00
eval "$(ssh-agent -s)"
ssh-add ./id_ed25519
2024-11-07 22:14:45 +00:00
apt-get update
2024-11-07 22:37:40 +00:00
apt-get install -y rsync
2024-11-07 22:43:38 +00:00
rsync -avz --delete --exclude=".env" --exclude="storage/logs/laravel.log" --exclude="laravel/node_modules" -e "ssh -i ./id_ed25519 -o StrictHostKeyChecking=no" ./ albert@217.160.204.114:/var/www/vhosts/electricistasdana.com/httpdocs