[instance] configure base-url if present in pillars
authorArthur Lutz <arthur.lutz@logilab.fr>
Thu, 13 Nov 2014 15:32:22 +0100
changeset 12 8eb0088192b5
parent 11 25876e1446db
child 13 e0a821c1c22a
[instance] configure base-url if present in pillars
cubicweb/instances.sls
--- a/cubicweb/instances.sls	Thu Nov 13 15:31:59 2014 +0100
+++ b/cubicweb/instances.sls	Thu Nov 13 15:32:22 2014 +0100
@@ -51,6 +51,13 @@
     - name: {{name}}
     - require:
       - cubicweb_instance: cw-{{vhostname}}-{{name}}
+
+configure cw-{{vhostname}}-{{name}}:
+    ini.options_present:
+        - name: /etc/cubicweb.d/{{name}}/all-in-one.conf
+        - sections: 
+            WEB:
+                base-url: http://{{vhostname}}
  {% endfor %}
 {% endfor %}