Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3766542
D3181.id8107.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
8 KB
Referenced Files
None
Subscribers
None
D3181.id8107.diff
View Options
diff --git a/pillar/devserver/datacubes.sls b/pillar/devserver/datacubes.sls
--- a/pillar/devserver/datacubes.sls
+++ b/pillar/devserver/datacubes.sls
@@ -39,3 +39,19 @@
user: web-be-dereckson-mw
group: dereckson
mode: 771
+
+ # Staging area for Zed
+
+ /var/dataroot/zed:
+ user: dereckson
+ mode: 711
+
+ /var/dataroot/zed/cache:
+ user: web-be-dereckson-zed51
+ group: dereckson
+ mode: 771
+
+ /var/dataroot/zed/content:
+ user: web-be-dereckson-zed51
+ group: dereckson
+ mode: 771
diff --git a/pillar/paas/alkane/windriver/main.sls b/pillar/paas/alkane/windriver/main.sls
--- a/pillar/paas/alkane/windriver/main.sls
+++ b/pillar/paas/alkane/windriver/main.sls
@@ -85,6 +85,16 @@
user: web-be-dereckson-www51
php-fpm: prod
+ # Zed
+ zed51.dereckson.be:
+ domain: dereckson.be
+ subdomain: zed51
+ user: web-be-dereckson-zed51
+ php-fpm: prod
+ env:
+ CACHE_DIR: /var/dataroot/zed/cache
+ CONTENT_DIR: /var/dataroot/zed/content
+
# Espace Win
www51.espace-win.org:
domain: espace-win.org
@@ -101,6 +111,7 @@
nginx_vhosts:
dereckson.be:
- mediawiki
+ - zed51
nasqueron.org:
- api51
diff --git a/roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf b/roles/webserver-alkane/nginx/files/vhosts/dereckson.be/zed51.conf
copy from roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf
copy to roles/webserver-alkane/nginx/files/vhosts/dereckson.be/zed51.conf
--- a/roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf
+++ b/roles/webserver-alkane/nginx/files/vhosts/dereckson.be/zed51.conf
@@ -1,9 +1,10 @@
# -------------------------------------------------------------
# Webserver
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-# Site: hypership.space
+# Site: zed51.dereckson.be
+# Description: Staging area for hypership.space
# License: Trivial work, not eligible to copyright
-# Source file: roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf
+# Source file: roles/webserver-alkane/nginx/files/vhosts/dereckson.be/zed51.conf
# -------------------------------------------------------------
#
# <auto-generated>
@@ -14,29 +15,44 @@
# </auto-generated>
# -------------------------------------------------------------
-# Main application
+# Redirect from port 80
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
server {
- server_name hypership.space;
+ listen 80;
+ listen [::]:80;
+ server_name zed51.dereckson.be;
+
+ include includes/letsencrypt;
+
+ location / {
+ return 301 https://zed51.dereckson.be$request_uri;
+ }
+}
+
+# -------------------------------------------------------------
+# Development and staging area
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+server {
+ server_name zed51.dereckson.be;
include includes/tls;
- ssl_certificate /usr/local/etc/letsencrypt/live/hypership.space/fullchain.pem;
- ssl_certificate_key /usr/local/etc/letsencrypt/live/hypership.space/privkey.pem;
+ ssl_certificate /usr/local/etc/letsencrypt/live/zed51.dereckson.be/fullchain.pem;
+ ssl_certificate_key /usr/local/etc/letsencrypt/live/zed51.dereckson.be/privkey.pem;
- error_log /var/log/www/hypership.space/www-error.log;
- access_log /var/log/www/hypership.space/www-access.log;
+ include includes/letsencrypt;
location /content {
return 403;
}
location /content/users {
- alias /srv/zed/content/users;
+ alias /var/dataroot/zed/content/users;
}
location /content/scenes {
- alias /srv/zed/content/scenes;
+ alias /var/dataroot/zed/content/scenes;
location ~ \.tpl$ {
# This folder contains templates intended to be rendered,
@@ -46,58 +62,30 @@
}
location / {
- return 503;
- }
-}
-
-# -------------------------------------------------------------
-# Redirects from port 80 and alternative domains
-# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
-server {
- listen 80;
- listen [::]:80;
- server_name hypership.space;
-
- include includes/letsencrypt;
-
- location / {
- return 301 https://hypership.space$request_uri;
- }
-}
-
-server {
- listen 80;
- listen [::]:80;
- server_name www.hypership.space zed.dereckson.be;
+ root /var/51-wwwroot/zed;
- include includes/tls;
- ssl_certificate /usr/local/etc/letsencrypt/live/hypership.space/fullchain.pem;
- ssl_certificate_key /usr/local/etc/letsencrypt/live/hypership.space/privkey.pem;
-
- include includes/letsencrypt;
+ # Currently not try_files as we use this block to add caching information in prod
+ if (-f $request_filename) {
+ break;
+ }
- location / {
- return 301 https://hypership.space$request_uri;
+ # Sends all non existing file or directory requests to index.php
+ if (!-e request_filename) {
+ rewrite ^/api\.php /api.php last;
+ rewrite ^/do\.php /do.php last;
+ rewrite ^(.+)$ /index.php last;
+ }
}
-}
-# -------------------------------------------------------------
-# Development and staging area
-# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
-server {
- listen 80;
- listen [::]:80;
- server_name zed51.dereckson.be;
+ #location ~ [^/]\.php(/|$) {
+ location ~ \.php$ {
+ fastcgi_pass unix:/var/run/web/zed51.dereckson.be/php-fpm.sock;
+ fastcgi_param SCRIPT_FILENAME /var/51-wwwroot/zed$fastcgi_script_name;
+ include includes/fastcgi;
+ fastcgi_index index.php;
- include includes/tls;
- ssl_certificate /usr/local/etc/letsencrypt/live/zed51.dereckson.be/fullchain.pem;
- ssl_certificate_key /usr/local/etc/letsencrypt/live/zed51.dereckson.be/privkey.pem;
-
- include includes/letsencrypt;
-
- location / {
- return 503;
+ # fastcgi_split_path_info ^((?U).+\.php)(.*)$;
+ # fastcgi_param PATH_INFO $fastcgi_path_info;
+ # fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
}
}
diff --git a/roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf b/roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf
--- a/roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf
+++ b/roles/webserver-alkane/nginx/files/vhosts/hypership.space/www.conf
@@ -45,8 +45,39 @@
}
}
- location / {
+ location /buildergate {
return 503;
+
+ # Serve through Apache
+
+ #rewrite /buildergate/(.*) /$1 break;
+ #proxy_pass http://localhost:3200;
+ #proxy_redirect off;
+ #proxy_set_header Host builder.zed.dereckson.be;
+ #proxy_set_header X-Real-IP $remote_addr;
+ #proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ }
+
+ location / {
+ # Serves static files if they exists, with one month cache
+ if (-f $request_filename) {
+ expires 30d;
+ break;
+ }
+
+ # Sends all non existing file or directory requests to index.php
+ if (!-e request_filename) {
+ rewrite ^/api\.php /api.php last;
+ rewrite ^/do\.php /do.php last;
+ rewrite ^(.+)$ /index.php last;
+ }
+ }
+
+ location ~ \.php$ {
+ fastcgi_pass unix:/var/run/web/hypership.space/php-fpm.sock;
+ fastcgi_index index.php;
+ fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
+ include includes/fastcgi;
}
}
@@ -81,23 +112,3 @@
return 301 https://hypership.space$request_uri;
}
}
-
-# -------------------------------------------------------------
-# Development and staging area
-# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
-server {
- listen 80;
- listen [::]:80;
- server_name zed51.dereckson.be;
-
- include includes/tls;
- ssl_certificate /usr/local/etc/letsencrypt/live/zed51.dereckson.be/fullchain.pem;
- ssl_certificate_key /usr/local/etc/letsencrypt/live/zed51.dereckson.be/privkey.pem;
-
- include includes/letsencrypt;
-
- location / {
- return 503;
- }
-}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 23, 18:47 (18 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2258117
Default Alt Text
D3181.id8107.diff (8 KB)
Attached To
Mode
D3181: Serve zed51.dereckson.be on devserver
Attached
Detach File
Event Timeline
Log In to Comment