2022-12-16 13:36:11 +01:00
|
|
|
echo "[1/7] Stopping server..."
|
2020-10-26 23:29:32 +01:00
|
|
|
sudo supervisorctl stop caps
|
2022-12-16 13:36:11 +01:00
|
|
|
echo "[2/7] Changing permissions..."
|
2020-10-26 23:29:32 +01:00
|
|
|
sudo chown -R pi:pi .
|
2022-12-16 13:36:11 +01:00
|
|
|
echo "[3/7] Pulling changes..."
|
2022-05-24 14:36:00 +02:00
|
|
|
git pull
|
2022-12-16 13:36:11 +01:00
|
|
|
echo "[4/7] Building project..."
|
2020-10-26 23:29:32 +01:00
|
|
|
swift build -c release
|
2022-12-16 13:36:11 +01:00
|
|
|
echo "[5/7] Restoring permissions..."
|
2020-10-26 23:29:32 +01:00
|
|
|
sudo chown -R www-data:www-data .
|
2022-12-16 13:36:11 +01:00
|
|
|
echo "[6/7] Starting server..."
|
2022-05-24 14:36:00 +02:00
|
|
|
sudo supervisorctl start caps
|
2022-12-16 13:36:11 +01:00
|
|
|
echo "[7/7] Done"
|