From 138a522f3f5ecee8fcab285a0556886088d68a85 Mon Sep 17 00:00:00 2001 From: Cody Hiar Date: Mon, 23 Mar 2015 15:22:08 -0600 Subject: [PATCH] Update standard.sls Create the vhost DocumentRoot directory if it does not exist --- apache/vhosts/standard.sls | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/apache/vhosts/standard.sls b/apache/vhosts/standard.sls index 28e7608..bbf3fdd 100644 --- a/apache/vhosts/standard.sls +++ b/apache/vhosts/standard.sls @@ -19,6 +19,11 @@ include: - pkg: apache - watch_in: - module: apache-reload + +{{ id }}-documentroot: + file.directory: + - unless: test -d {{ site.get('DocumentRoot') }} + - name: {{ site.get('DocumentRoot') }} {% if grains.os_family == 'Debian' %} a2ensite {{ id }}{{ apache.confext }}: