aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/constant-sync.sh5
-rwxr-xr-xscripts/deploy.sh (renamed from scripts/setup.sh)7
-rwxr-xr-xscripts/setup-test.sh5
3 files changed, 7 insertions, 10 deletions
diff --git a/scripts/constant-sync.sh b/scripts/constant-sync.sh
deleted file mode 100755
index c016b44..0000000
--- a/scripts/constant-sync.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/bash
-while true; do
- rsync -av --delete ./zola-static/public/ /var/www/homepage/
- sleep 5 # wait 5 seconds before the next sync
-done
diff --git a/scripts/setup.sh b/scripts/deploy.sh
index 49ba2d7..56661c5 100755
--- a/scripts/setup.sh
+++ b/scripts/deploy.sh
@@ -1,5 +1,12 @@
#!/bin/bash
+# grab latest
+git pull
+
+# setup gninx
cp ./nginx/homepage.conf /etc/nginx/sites-enabled/homepage.conf
mkdir /var/www/homepage/
+
+# build and sync zola
+(cd zola-static && zola build)
rsync -av --delete ./zola-static/public/ /var/www/homepage/
diff --git a/scripts/setup-test.sh b/scripts/setup-test.sh
deleted file mode 100755
index 133705e..0000000
--- a/scripts/setup-test.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/bash
-
-cp ./nginx/homepage-testing.conf /etc/nginx/sites-enabled/homepage.conf
-mkdir /var/www/homepage/
-rsync -av --delete ./zola-static/public/ /var/www/homepage/