BaseBandRewrite/scripts/push_file.sh

10 lines
380 B
Bash
Raw Normal View History

#!/bin/bash
# DO NOT RUN THIS MANUALLY. PUSH TO RELEASE INSTEAD. ( <- unless there is an emergency.)
2024-06-09 12:08:48 +02:00
echo "$SSH_PRIVATEKEY" > ssh_key
chmod 700 ssh_key
2024-06-10 21:18:31 +02:00
scp -o StrictHostKeyChecking=no -i ssh_key -P "$BB_PORT" "$1" "root@$BB_HOST:$BB_PATH" &&
(ssh -o StrictHostKeyChecking=no -i ssh_key -p "$BB_PORT" "root@$BB_HOST" "cd $BB_PATH && bash $(basename "$1").sh" || true)
2024-06-09 12:08:48 +02:00
rm ssh_key