blog/restart.sh
ajet cc13b521ae
All checks were successful
Deploy ${{ gitea.repository }} / build (push) Successful in 1m3s
perms
2025-11-15 20:28:55 -10:00

14 lines
363 B
Bash
Executable File

#!/bin/bash
set -ve
JOB_URL=$(curl https://git.ajet.fyi/api/v1/repos/ajet-industries/blog/actions/tasks | jq '.workflow_runs[0].url' -r)
echo $JOB_URL
ARTIFACT_URL="$JOB_URL/artifacts/blog"
echo $ARTIFACT_URL
rm /var/www/html/* -rf || echo "files not found to delete"
cd /var/www/html
curl $ARTIFACT_URL --output blog
unzip blog
rm blog
systemctl restart nginx