File tree 2 files changed +9
-0
lines changed
templates/etc/apache2/sites-available/site
2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change 14
14
# apache2_sites:
15
15
# - id: mysite (required)
16
16
# name: mysite.local (required)
17
+ # document_root: ""
17
18
# ip: '*'
18
19
# port: 80
19
20
# state: present
Original file line number Diff line number Diff line change 1
1
ServerName {{ item.name }}
2
+ {% if item .document_root is defined %}
3
+ DocumentRoot {{ item.document_root }}
4
+ {% else %}
2
5
DocumentRoot {{ apache2_sites_basedir }}/{{ item.id }}/htdocs
6
+ {% endif %}
3
7
{% for value in item .aliases |default ([]) %}
4
8
ServerAlias {{ value }}
5
9
{% endfor %}
12
16
13
17
# --- directories -----------------------------------------------------------
14
18
19
+ {% if item .document_root is defined %}
20
+ <Directory {{ item.document_root }} >
21
+ {% else %}
15
22
<Directory {{ apache2_sites_basedir }} /{{ item.id }} /htdocs >
23
+ {% endif %}
16
24
AllowOverride All
17
25
Options FollowSymLinks
18
26
Require all granted
You can’t perform that action at this time.
0 commit comments