From b74bd67a4a25076812e86e7989a63b9540e68b25 Mon Sep 17 00:00:00 2001 From: Lizzy Hunt Date: Sun, 10 Mar 2024 01:41:11 -0700 Subject: attempt systemd deployment --- deploy.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'deploy.sh') diff --git a/deploy.sh b/deploy.sh index 06e13df..322c5b9 100755 --- a/deploy.sh +++ b/deploy.sh @@ -1,10 +1,12 @@ -#!/bin/sh +#!/bin/bash set -e echo $SSH_KEY | base64 -d >> /tmp/key chmod -R 0600 /tmp/key +rsync -e "ssh -i /tmp/key -o StrictHostKeyChecking=no" -avz --delete ./systemd/ $RSYNC_DESTINATION/.config/systemd/user/ + cd dist for item in *; do echo "copying $item" @@ -20,4 +22,7 @@ done cd .. echo "finished copying to remote host..." +ssh -i /tmp/key -o StrictHostKeyChecking=no $(echo "${$RSYNC_DESTINATION%%:*}") "systemctl daemon reload --user && systemctl restart --user fruitvote" +echo "reloading fruitvote..." + rm /tmp/key -- cgit v1.2.3-70-g09d2