This means a bit more adjustment on the part of developers that aren't familiar with how Go does things, but it makes it more consistent and easier to work with when on multiple Go projects.
18 lines
677 B
Bash
Executable File
18 lines
677 B
Bash
Executable File
#!/bin/bash -e
|
|
|
|
# Deploys onto biflamanager
|
|
DEPLOYHOST=biflamanager
|
|
DEPLOYPATH=/home/flamanager/ # end in slash!
|
|
SSH="ssh -o ClearAllForwardings=yes"
|
|
|
|
echo "======== Building a statically-linked Flamenco Manager"
|
|
bash docker/build-via-docker.sh linux
|
|
|
|
echo "======== Deploying onto $DEPLOYHOST"
|
|
$SSH $DEPLOYHOST -t "sudo systemctl stop flamenco-manager.service"
|
|
rsync -e "$SSH" -va docker/flamenco-manager-linux $DEPLOYHOST:$DEPLOYPATH/flamenco-manager --delete-after
|
|
rsync -e "$SSH" -va templates static $DEPLOYHOST:$DEPLOYPATH --delete-after --exclude static/latest-image.jpg
|
|
$SSH $DEPLOYHOST -t "sudo systemctl start flamenco-manager.service"
|
|
|
|
echo "======== Deploy done."
|