This commit is contained in:
2026-03-10 14:35:04 +03:00
parent 8fa7d13072
commit ab1d4c72fa
6 changed files with 263 additions and 26 deletions

13
4/deploy.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/bash
set -exu
SERVER=root@185.103.252.32
PSQL="sudo -u postgres psql"
DB=db2026
scp schema.sql data.sql "$SERVER:/tmp/$DB/"
ssh $SERVER \
"chmod -R 777 /tmp/$DB;" \
"$PSQL -d $DB -e -q -f /tmp/$DB/schema.sql;" \
"$PSQL -d $DB -e -q -f /tmp/$DB/data.sql;"