diff options
Diffstat (limited to 'deploy.sh')
-rwxr-xr-x | deploy.sh | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/deploy.sh b/deploy.sh new file mode 100755 index 0000000..d66afa0 --- /dev/null +++ b/deploy.sh @@ -0,0 +1,18 @@ +#!/usr/bin/env bash + +set -e + +# Copy static site +hugo +scp -r public/* root@rpi3:/var/www/mfashby.net/ + +# build & install comments app +pushd comments +RUSTFLAGS="-C linker=aarch64-linux-gnu-gcc" cargo build --target=aarch64-unknown-linux-gnu --release +ssh root@rpi3 -C systemctl stop comments +scp target/aarch64-unknown-linux-gnu/release/comments root@rpi3:/usr/local/bin/comments +scp comments.service root@rpi3:/etc/systemd/system/comments.service +ssh root@rpi3 -C systemctl daemon-reload +ssh root@rpi3 -C systemctl restart comments +popd + |