Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3749907
D1672.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
4 KB
Referenced Files
None
Subscribers
None
D1672.diff
View Options
diff --git a/PORTS b/PORTS
--- a/PORTS
+++ b/PORTS
@@ -1,3 +1,4 @@
paas-docker
+ 31080 Phabricator HTTP - DevCentral
38080 Jenkins HTTP - CD
50000 Jenkins master's port for JNLP-based Jenkins agents - CD
diff --git a/pillar/paas/docker.sls b/pillar/paas/docker.sls
--- a/pillar/paas/docker.sls
+++ b/pillar/paas/docker.sls
@@ -52,6 +52,10 @@
elapsi:
ip: 172.17.0.101
+ # Infrastructure and development services
+ phabricator:
+ devcentral: {}
+
# phpBB SaaS
# The SaaS uses a MySQL instance, declared in the MySQL section.
diff --git a/roles/paas-docker/containers/phabricator.sls b/roles/paas-docker/containers/phabricator.sls
new file mode 100644
--- /dev/null
+++ b/roles/paas-docker/containers/phabricator.sls
@@ -0,0 +1,35 @@
+# -------------------------------------------------------------
+# Salt — Provision Docker engine
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+# Project: Nasqueron
+# Created: 2018-09-06
+# License: Trivial work, not eligible to copyright
+# -------------------------------------------------------------
+
+{% set has_selinux = salt['grains.get']('selinux:enabled', False) %}
+{% set containers = pillar['docker_containers'][grains['id']] %}
+
+{% for instance in containers['phabricator'] %}
+
+# -------------------------------------------------------------
+# Storage directory
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+/srv/{{ instance }}:
+ file.directory:
+ - user: 431
+ - group: 433
+ - makedirs: True
+
+{% if has_selinux %}
+selinux_context_{{ instance }}_data:
+ selinux.fcontext_policy_present:
+ - name: /srv/{{ instance }}
+ - sel_type: svirt_sandbox_file_t
+
+selinux_context_{{ instance }}_data_applied:
+ selinux.fcontext_policy_applied:
+ - name: /srv/{{ instance }}
+{% endif %}
+
+{% endfor %}
diff --git a/roles/paas-docker/nginx/files/vhosts/devcentral.conf b/roles/paas-docker/nginx/files/vhosts/devcentral.conf
new file mode 100644
--- /dev/null
+++ b/roles/paas-docker/nginx/files/vhosts/devcentral.conf
@@ -0,0 +1,80 @@
+server {
+ listen 80;
+ listen [::]:80;
+ server_name phabricator.nasqueron.org;
+
+ include includes/letsencrypt;
+
+ include includes/tls;
+ ssl_certificate /srv/letsencrypt/etc/live/devcentral.nasqueron.org/fullchain.pem;
+ ssl_certificate_key /srv/letsencrypt/etc/live/devcentral.nasqueron.org/privkey.pem;
+
+ rewrite ^ https://devcentral.nasqueron.org$request_uri? permanent;
+}
+
+server {
+ listen 80;
+ listen [::]:80;
+ server_name phabricator-files-for-devcentral-nasqueron.spacetechnology.net;
+
+ return 301 https://$host$request_uri;
+}
+
+server {
+ server_name phabricator-files-for-devcentral-nasqueron.spacetechnology.net;
+
+ include includes/letsencrypt;
+
+ include includes/tls;
+ ssl_certificate /srv/letsencrypt/etc/live/devcentral.nasqueron.org/fullchain.pem;
+ ssl_certificate_key /srv/letsencrypt/etc/live/devcentral.nasqueron.org/privkey.pem;
+
+ include includes/proxy_params;
+ location / {
+ proxy_pass http://localhost:31080;
+ }
+}
+
+server {
+ listen 80;
+ listen [::]:80;
+ server_name devcentral.nasqueron.org;
+
+ return 301 https://$host$request_uri;
+}
+
+server {
+ server_name devcentral.nasqueron.org;
+
+ include includes/letsencrypt;
+
+ include includes/tls;
+ ssl_certificate /srv/letsencrypt/etc/live/devcentral.nasqueron.org/fullchain.pem;
+ ssl_certificate_key /srv/letsencrypt/etc/live/devcentral.nasqueron.org/privkey.pem;
+
+ include includes/proxy_params;
+ location / {
+ proxy_pass http://localhost:31080;
+ }
+
+ location ~ ^/maniphest/task/create {
+ rewrite ^/maniphest/task/create/?(.*) /maniphest/task/edit/form/1/$1;
+ }
+
+ #502 error
+ root /var/wwwroot-502/devcentral.nasqueron.org;
+ error_page 502 /502.html;
+ location /502.html {}
+}
+
+server {
+ listen 80;
+ listen [::]:80;
+ server_name server.nasqueron.org serveur.nasqueron.org serveurs.nasqueron.org;
+
+ include includes/letsencrypt; include includes/tls;
+ ssl_certificate /srv/letsencrypt/etc/live/devcentral.nasqueron.org/fullchain.pem;
+ ssl_certificate_key /srv/letsencrypt/etc/live/devcentral.nasqueron.org/privkey.pem;
+
+ rewrite ^ https://servers.nasqueron.org$request_uri? permanent;
+}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 17, 18:57 (21 h, 7 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2249747
Default Alt Text
D1672.diff (4 KB)
Attached To
Mode
D1672: Migrate DevCentral container to Equatower
Attached
Detach File
Event Timeline
Log In to Comment