2018-12-08 13:50:44 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if [ ! -f /data/mumo.ini ]
|
|
|
|
then
|
2020-08-16 23:35:23 +02:00
|
|
|
cp -r /mumo/mumo.ini /mumo/modules /mumo/modules-available /data
|
2018-12-08 13:50:44 +01:00
|
|
|
mkdir -p /data/modules-enabled
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Mumo apparently refuses to read config from mounted dirs,
|
|
|
|
# so we copy them ...
|
|
|
|
cp -r /data/mumo.ini /mumo
|
2020-08-16 20:59:04 +02:00
|
|
|
|
2020-08-16 23:35:23 +02:00
|
|
|
# if additional configuration is defined, we will replace our local default config.
|
|
|
|
[ -d /data/modules-enabled ] && cp -r /data/modules-enabled /mumo
|
|
|
|
[ -d /data/modules ] && rm -rf /mumo/modules && cp -r /data/modules /mumo
|
|
|
|
|
|
|
|
# make sure our dir is writable for the user
|
|
|
|
chown mumo:mumo /mumo -R
|
|
|
|
|
|
|
|
exec su mumo -c "python3 /mumo/mumo.py --app --ini /mumo/mumo.ini"
|