From e95a82f67d38089d9535ddae1b8acf8a14d30a21 Mon Sep 17 00:00:00 2001 From: Urban Guacamole Date: Wed, 25 Dec 2019 13:25:26 +0100 Subject: [PATCH] Update deploy scripts --- static/deploy.sh | 2 ++ update-index.sh | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 static/deploy.sh diff --git a/static/deploy.sh b/static/deploy.sh new file mode 100644 index 0000000..aa607fb --- /dev/null +++ b/static/deploy.sh @@ -0,0 +1,2 @@ +rsync -ar ./ root@server:/www/torrent-paradise.ml +# also purge CDN cache \ No newline at end of file diff --git a/update-index.sh b/update-index.sh index 9fc2c69..ca7afc0 100755 --- a/update-index.sh +++ b/update-index.sh @@ -1,5 +1,3 @@ -# This script updates the index. Testing and uploading to server/IPFS is done manually. - echo "Refreshing database" ssh nextgen@server "psql -c 'REFRESH MATERIALIZED VIEW fresh'" echo "Downloading dump" @@ -12,4 +10,6 @@ echo "Generating top torrents list" generate-top-torrents/generate-top-torrents > website/generated/top.json echo "Uploading website" cd website -rsync -ar ./ root@server:/www/torrent-paradise.ml # consider using --progress \ No newline at end of file +rsync -ar ./ root@server:/www/ipfs-torrent-paradise # consider using --progress +echo "Adding to IPFS" +ssh root@server "bash /root/upload-website.sh"