From 009aea55a7defd08640a96f67a99001e18930c74 Mon Sep 17 00:00:00 2001 From: Stephen Cochrane Date: Thu, 15 Oct 2020 19:44:30 +0200 Subject: [PATCH] Added disable units --- nginxd | 3 +++ units/dblog | 12 ++++++++++++ units/dgit | 12 ++++++++++++ units/dirc | 12 ++++++++++++ units/dproj | 12 ++++++++++++ units/dwiki | 12 ++++++++++++ 6 files changed, 63 insertions(+) create mode 100644 units/dblog create mode 100644 units/dgit create mode 100644 units/dirc create mode 100644 units/dproj create mode 100644 units/dwiki diff --git a/nginxd b/nginxd index 7f889d5..575c8ac 100755 --- a/nginxd +++ b/nginxd @@ -35,12 +35,15 @@ link () { # add [unit] add () { echo TODO: Enable $1 + cp $unitsd/$1 /etc/nginx/sites-available + link $1 } # Remove a unit so that nginx does not use it anymore, also sets up sym links. # remove [unit] remove () { echo TODO: Remove $1 + rm /etc/nginx/sites-enabled/$1 } # Enable or disable all units. diff --git a/units/dblog b/units/dblog new file mode 100644 index 0000000..d8db4ca --- /dev/null +++ b/units/dblog @@ -0,0 +1,12 @@ +server { + listen 80; + server_name blog.skiqqy.xyz; + + location / { + proxy_pass http://localhost:79/error/blog.html; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + } +} diff --git a/units/dgit b/units/dgit new file mode 100644 index 0000000..fdb6436 --- /dev/null +++ b/units/dgit @@ -0,0 +1,12 @@ +server { + listen 80; + server_name git.skiqqy.xyz; + + location / { + proxy_pass http://localhost:79/error/git.html; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + } +} diff --git a/units/dirc b/units/dirc new file mode 100644 index 0000000..3a0cd12 --- /dev/null +++ b/units/dirc @@ -0,0 +1,12 @@ +server { + listen 80; + server_name irc.skiqqy.xyz; + + location / { + proxy_pass http://localhost:79/error/irc.html; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + } +} diff --git a/units/dproj b/units/dproj new file mode 100644 index 0000000..0a901e7 --- /dev/null +++ b/units/dproj @@ -0,0 +1,12 @@ +server { + listen 80; + server_name proj.skiqqy.xyz; + + location / { + proxy_pass http://localhost:79/error/proj.html; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + } +} diff --git a/units/dwiki b/units/dwiki new file mode 100644 index 0000000..f21ac23 --- /dev/null +++ b/units/dwiki @@ -0,0 +1,12 @@ +server { + listen 80; + server_name wiki.skiqqy.xyz; + + location / { + proxy_pass http://localhost:79/error/wiki.html; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + } +}