depot/hack/deploy.sh

16 lines
348 B
Bash
Raw Normal View History

#!/usr/bin/env bash
set -euo pipefail
./hack/populate_secrets.sh
2020-05-09 23:12:25 +00:00
ssh_cmd="ssh -o StrictHostKeyChecking=accept-new"
if [ ! -z ${2+x} ]; then ssh_cmd="$ssh_cmd $2"; fi
echo Syncing repo content to machine "$1"
rsync -e "$ssh_cmd" -avz --exclude='.hg/' ./ "deployer@$1:depot/"
echo Triggering rebuild
2020-05-09 22:49:32 +00:00
$ssh_cmd -t "deployer@$1" rebuilder ./depot