2
0

exercice variable: mise au point 17.3, qui devrait remplacer les autres

This commit is contained in:
2018-07-06 11:14:28 +02:00
parent ec07976964
commit 46153d62e4
7 changed files with 26 additions and 17 deletions

View File

@@ -1,7 +1,9 @@
{% for vhost in apache_vhosts %}
<VirtualHost *:{{ http_port }}>
ServerName {{ vhost.servername }}
ServerAlias {{ vhost.serveralias }}
{% for alias in vhost.serveralias %}
ServerAlias {{ alias }}
{% endfor %}
DocumentRoot {{ vhost.documentroot }}
CustomLog {{ vhost.accesslog }} combined
ErrorLog {{ vhost.errorlog }}

View File

@@ -1,15 +1,3 @@
---
# vars file for myapache
http_port: 80
apache_vhosts:
- servername: orsys.fr
serveralias: www.orsys.fr
documentroot: /var/www/html/orsys.fr
accesslog: /var/log/httpd/access_orsys.fr_log
errorlog: /var/log/httpd/error_orsys.fr_log
- servername: thomas.fr
serveralias: www.thomas.fr
documentroot: /var/www/html/thomas.fr
accesslog: /var/log/httpd/access_thomas.fr_log
errorlog: /var/log/httpd/error_thomas.fr_log
documentrootoptions: indexes
http_port: 80