mirror of
https://github.com/CPunch/openpunk-ansible.git
synced 2025-10-15 21:50:09 +00:00
blog: maintain two separate builds of the site; one for tor, one for https
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
repo: "https://github.com/CPunch/openpunk.git"
|
||||
dest: "/var/www/{{ domain }}"
|
||||
|
||||
# TODO: make idempotent
|
||||
# TODO: make idempotent (call the updateBlog script !!)
|
||||
- name: Build blog
|
||||
command:
|
||||
cmd: hugo
|
||||
|
@@ -2,4 +2,7 @@
|
||||
cd /var/www/{{ domain }}
|
||||
/usr/bin/git fetch origin
|
||||
/usr/bin/git reset --hard origin/main
|
||||
/usr/bin/hugo
|
||||
|
||||
# build sites
|
||||
/usr/bin/hugo --cleanDestinationDir --minify -d public -b https://{{ domain }}
|
||||
/usr/bin/hugo --cleanDestinationDir --minify -d tor -b {{ onionDomain }}
|
||||
|
@@ -16,3 +16,5 @@ sed -i 's/--DATE--/'$currDate'/g' $pageName
|
||||
git add .
|
||||
git commit -m "DeadSwitch: No response from CPunch in 14 days, posting dead.md"
|
||||
git push --force
|
||||
|
||||
updateBlog
|
@@ -27,8 +27,6 @@
|
||||
template:
|
||||
src: templates/tor.conf
|
||||
dest: /etc/nginx/conf.d/tor-{{ domain }}.conf
|
||||
force: no
|
||||
notify: setup nginx
|
||||
|
||||
- name: Enable Nginx
|
||||
systemd:
|
||||
|
@@ -1,5 +1,5 @@
|
||||
server {
|
||||
root /var/www/{{ domain }}/public;
|
||||
root /var/www/{{ domain }}/tor;
|
||||
index index.html index.htm;
|
||||
|
||||
location / {
|
||||
|
Reference in New Issue
Block a user