-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathdocker-entrypoint.sh
More file actions
executable file
·35 lines (32 loc) · 976 Bytes
/
docker-entrypoint.sh
File metadata and controls
executable file
·35 lines (32 loc) · 976 Bytes
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
#!/bin/sh
edit_icecast_config() {
xml-edit "$@" /etc/icecast.xml
}
if [ -n "$ICECAST_SOURCE_PASSWORD" ]; then
edit_icecast_config source-password "$ICECAST_SOURCE_PASSWORD"
fi
if [ -n "$ICECAST_RELAY_PASSWORD" ]; then
edit_icecast_config relay-password "$ICECAST_RELAY_PASSWORD"
fi
if [ -n "$ICECAST_ADMIN_PASSWORD" ]; then
edit_icecast_config admin-password "$ICECAST_ADMIN_PASSWORD"
fi
if [ -n "$ICECAST_ADMIN_USERNAME" ]; then
edit_icecast_config admin-user "$ICECAST_ADMIN_USERNAME"
fi
if [ -n "$ICECAST_ADMIN_EMAIL" ]; then
edit_icecast_config admin "$ICECAST_ADMIN_EMAIL"
fi
if [ -n "$ICECAST_LOCATION" ]; then
edit_icecast_config location "$ICECAST_LOCATION"
fi
if [ -n "$ICECAST_HOSTNAME" ]; then
edit_icecast_config hostname "$ICECAST_HOSTNAME"
fi
if [ -n "$ICECAST_MAX_CLIENTS" ]; then
edit_icecast_config clients "$ICECAST_MAX_CLIENTS"
fi
if [ -n "$ICECAST_MAX_SOURCES" ]; then
edit_icecast_config sources "$ICECAST_MAX_SOURCES"
fi
exec "$@"