summaryrefslogtreecommitdiff
path: root/roles/streaming/icecast/templates/pod-spec.yml.j2
blob: bac1ac3b0956cfe2256f6dbc6d0df81e75bcb52b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
securityContext:
  allowPrivilegeEscalation: false
  runAsUser: 990
  runAsGroup: 990
containers:
- name: icecast
  image: registry.gitlab.com/spreadspace/docker/icecast:{{ item.value.image_version }}
  imagePullPolicy: Always
  resources:
    limits:
      memory: "512Mi"
  args:
  - icecast2
  - -c
  - /srv/icecast.xml
  volumeMounts:
  - name: home
    mountPath: /srv/icecast.xml
    subPath: icecast.xml
    readOnly: true
  - name: home
    mountPath: /srv/logs
    subPath: logs
  ports:
{% for listener in item.value.listeners %}
  - containerPort: {{ listener.port }}
    hostPort: {{ listener.port }}
{%   if 'shoutcast_mountpoint' in listener %}
  - containerPort: {{ listener.port + 1 }}
    hostPort: {{ listener.port + 1 }}
{%   endif  %}
{% endfor %}

volumes:
- name: home
  hostPath:
    path: "{{ icecast_base_path }}/{{ item.key }}"