Skip to content

Commit 9bed3f1

Browse files
committed
Add optional configuration for Apache virtualhost aliases
1 parent 180e35c commit 9bed3f1

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

defaults/main.yml

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
# zabbix role specific
44

55
zabbix_url: zabbix.example.com
6+
zabbix_url_aliases: []
67
zabbix_version: 2.4
78
zabbix_timezone: Europe/Amsterdam
89
zabbix_repo: True

templates/apache_vhost.conf.j2

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
<VirtualHost *:80>
22
ServerName {{ zabbix_url }}
3+
{% for alias in zabbix_url_aliases %}
4+
ServerAlias {{ alias }}
5+
{% endfor %}
36

47
## Vhost docroot
58
DocumentRoot "/usr/share/zabbix"

0 commit comments

Comments
 (0)