summaryrefslogtreecommitdiff
path: root/web/update-remote.sh
blob: 2dd9ce741ef8f78ff8f0038ff52d913f2d69d195 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh

REPLY=0
read -p "are you sure you want to update the remote website? (y/n) " REPLY

if [[ "$REPLY" == "y" ]]; then
  for i in $(ls -1 ./dist/); do
    echo "copying $i"
    scp -r ./dist/$i root@networkheaven.net:/var/www/html/
  done

  echo "clearing render cache..."
  ssh root@networkheaven.net -p22 "rm /home/web/render/cache/*"
  echo "done"
fi