Skip to content

Commit 3049a1e

Browse files
authored
SYS-641 fix mythtv-backend config.xml template substitution (#243)
1 parent d408438 commit 3049a1e

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

images/mythtv-backend/src/entrypoint.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,14 @@ if [ ! -f $MYTHHOME/.Xauthority ]; then
3434
fi
3535

3636
cp /root/config.xml /etc/mythtv/
37+
38+
# Substitute environment variables in config.xml
39+
sed -i -e "s/{{ DBNAME }}/$DBNAME/" \
40+
-e "s/{{ DBPASSWORD }}/$DBPASSWORD/" \
41+
-e "s/{{ DBSERVER }}/$DBSERVER/" \
42+
-e "s/{{ LOCALHOSTNAME }}/$LOCALHOSTNAME/" \
43+
/etc/mythtv/config.xml
44+
3745
chmod 600 /etc/mythtv/config.xml && chown mythtv /etc/mythtv/config.xml
3846

3947
for retry in $(seq 1 10); do

0 commit comments

Comments
 (0)