summaryrefslogtreecommitdiff
path: root/roles/streaming/icecast/templates/icecast.xml.j2
diff options
context:
space:
mode:
Diffstat (limited to 'roles/streaming/icecast/templates/icecast.xml.j2')
-rw-r--r--roles/streaming/icecast/templates/icecast.xml.j233
1 files changed, 23 insertions, 10 deletions
diff --git a/roles/streaming/icecast/templates/icecast.xml.j2 b/roles/streaming/icecast/templates/icecast.xml.j2
index 3bf0044a..60f6000f 100644
--- a/roles/streaming/icecast/templates/icecast.xml.j2
+++ b/roles/streaming/icecast/templates/icecast.xml.j2
@@ -1,9 +1,5 @@
<icecast>
<!-- ***** global ***** -->
- <listen-socket>
- <port>8080</port>
- </listen-socket>
-
<limits>
<threadpool>5</threadpool>
<queue-size>524288</queue-size>
@@ -15,8 +11,12 @@
</limits>
<authentication>
+{% if 'source_password' in item.value %}
<source-password>{{ item.value.source_password }}</source-password>
+{% endif %}
+{% if 'relay_password' in item.value %}
<relay-password>{{ item.value.relay_password }}</relay-password>
+{% endif %}
<admin-user>{{ item.value.admin.username }}</admin-user>
<admin-password>{{ item.value.admin.password }}</admin-password>
</authentication>
@@ -32,21 +32,34 @@
{% endif %}
+<!-- ***** listeners ***** -->
+{% for listener in item.value.listeners %}
+ <listen-socket>
+ <port>{{ listener.port }}</port>
+{% if 'shoutcast_mountpoint' in listener %}
+ <shoutcast-mount>{{ listener.shoutcast_mountpoint }}</shoutcast-mount>
+{% endif %}
+ </listen-socket>
+
+{% endfor %}
+
+{% if 'mountpoints' in item.value %}
<!-- ***** mountpoints ***** -->
-{% for mountpoint, config in item.value.mountpoints.items() %}
+{% for mountpoint, config in item.value.mountpoints.items() %}
<mount>
<mount-name>{{ mountpoint }}</mount-name>
-{% if 'username' in config %}
+{% if 'username' in config %}
<username>{{ config.username }}</username>
-{% endif %}
+{% endif %}
<password>{{ config.password }}</password>
-{% if 'max_listeners' in config %}
+{% if 'max_listeners' in config %}
<max-listeners>{{ config.max_listeners }}</max-listeners>
-{% endif %}
+{% endif %}
</mount>
-{% endfor %}
+{% endfor %}
+{% endif %}
<!-- ***** aux ***** -->
<fileserve>1</fileserve>
<paths>