Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3778800
D3300.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D3300.diff
View Options
diff --git a/PORTS b/PORTS
--- a/PORTS
+++ b/PORTS
@@ -48,6 +48,7 @@
46555 Airflow - Flower
47080 Jenkins HTTP - Test
48080 Vault - Notifications - Integration
+ 49080 Corspat HTTP
50000 Jenkins controller's port for JNLP-based Jenkins agents - CD
52000 Jenkins controller's port for JNLP-based Jenkins agents - Test
55000 Jenkins controller's port for JNKP-based Jenkins agents - CI
diff --git a/pillar/credentials/vault.sls b/pillar/credentials/vault.sls
--- a/pillar/credentials/vault.sls
+++ b/pillar/credentials/vault.sls
@@ -177,6 +177,7 @@
# Format: <project name>.<service>.<type>
#
+ - ops/secrets/corspat/smtp
- ops/secrets/dbserver/cluster-A/users/corspat
- ops/secrets/espacewin.phpbb.mysql_root
diff --git a/pillar/paas/docker/docker-002/corspat.sls b/pillar/paas/docker/docker-002/corspat.sls
new file mode 100644
--- /dev/null
+++ b/pillar/paas/docker/docker-002/corspat.sls
@@ -0,0 +1,12 @@
+docker_images:
+ - codrlabs/corspat
+
+docker_containers:
+ corspat:
+ corspat:
+ app_port: 49080
+ host: corspat.nasqueron.org
+ db: db-A
+ credentials:
+ db: dbserver/cluster-A/users/corspat
+ mail: corspat/smtp
diff --git a/roles/paas-docker/containers/corspat.sls b/roles/paas-docker/containers/corspat.sls
new file mode 100644
--- /dev/null
+++ b/roles/paas-docker/containers/corspat.sls
@@ -0,0 +1,32 @@
+# -------------------------------------------------------------
+# Salt — Provision Docker engine
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+# Project: Nasqueron
+# License: Trivial work, not eligible to copyright
+# -------------------------------------------------------------
+
+{% for instance, container in pillar['docker_containers']['corspat'].items() %}
+
+# -------------------------------------------------------------
+# Container
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+{% set dsn = salt["credentials.get_dsn"](pillar["nasqueron_services"][container["db"]], container["credentials"]["db"]) %}
+
+{{ instance }}:
+ docker_container.running:
+ - detach: True
+ - interactive: True
+ - image: codrlabs/corspat
+ - env:
+ - DATABASE_URL=postgres://{{ dsn }}/corspat
+ - DATABASE_URL_PSYCOPG=postgresql+psycopg2://{{ dsn }}/corspat
+
+ - MAIL_USERNAME={{ salt["credentials.get_username"](container["credentials"]["mail"]) }}
+ - MAIL_PASSWORD={{ salt["credentials.get_password"](container["credentials"]["mail"]) }}
+ - ports:
+ - 5000
+ - port_bindings:
+ - {{ container['app_port'] }}:5000
+
+{% endfor %}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 26, 06:19 (20 h, 34 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2263268
Default Alt Text
D3300.diff (2 KB)
Attached To
Mode
D3300: Deploy corspat container on Docker PaaS
Attached
Detach File
Event Timeline
Log In to Comment