Hello
I am trying to get 2 modipy instances of the same PI mopidy server.
I have a first server that delivers MUSIC files from an external hard drive on the port 6680 and I use Iris to interact. All is well.
On the same external hard drive I have a folder that holds audio SFX files.
I read the link below about setting up different instances off the same machine.
Sadly, the above discussion does not confirm that the system functions, but it looks promising. But … it does not work for me.
Firstly, when I restart the mopidy service, mopidy does not seem take into consideration the modification I made to the conf file in init.d
admin@pimusic:~ $ sudo systemctl status mopidy
* mopidy.service - Mopidy music server
Loaded: loaded (/lib/systemd/system/mopidy.service; enabled; vendor preset: enabled)
Active: active (running) since Wed 2021-08-25 17:24:58 CEST; 3s ago
Process: 1186 ExecStartPre=/bin/mkdir -p /var/cache/mopidy (code=exited, status=0/SUCCESS)
Process: 1187 ExecStartPre=/bin/chown mopidy:audio /var/cache/mopidy (code=exited, status=0/SUCCESS)
Main PID: 1188 (mopidy)
Tasks: 1 (limit: 4915)
CGroup: /system.slice/mopidy.service
`-1188 /usr/bin/python3 /usr/bin/mopidy --config /usr/share/mopidy/conf.d:/etc/mopidy/mopidy.conf
Aug 25 17:25:00 pimusic mopidy[1188]: ModuleNotFoundError: No module named 'mem'
Aug 25 17:25:00 pimusic mopidy[1188]: INFO [MainThread] mopidy.config Loading config from builtin defaults
Aug 25 17:25:00 pimusic mopidy[1188]: INFO [MainThread] mopidy.config Loading config from file:///usr/share/mopidy/conf.d/mopidy.conf
Aug 25 17:25:00 pimusic mopidy[1188]: INFO [MainThread] mopidy.config Loading config from file:///etc/mopidy/mopidy.conf
Aug 25 17:25:00 pimusic mopidy[1188]: INFO [MainThread] mopidy.config Loading config from command line options
Aug 25 17:25:00 pimusic mopidy[1188]: WARNING [MainThread] mopidy.config Ignoring config section 'moped' because no matching extension was foun
Aug 25 17:25:00 pimusic mopidy[1188]: WARNING [MainThread] mopidy.config Ignoring config section 'musicbox_webclient' because no matching exten
Aug 25 17:25:00 pimusic mopidy[1188]: WARNING [MainThread] mopidy.config Ignoring config section 'local-images' because no matching extension w
Aug 25 17:25:00 pimusic mopidy[1188]: INFO [MainThread] mopidy.__main__ Enabled extensions: mpd, local, mobile, iris, http, m3u, file, softw
Aug 25 17:25:00 pimusic mopidy[1188]: INFO [MainThread] mopidy.__main__ Disabled extensions: spotify
Below is the begining of the init.d/mopidy file. I declare 2 config files CONFIG_FILES=“/usr/share/mopidy/conf.d:/etc/mopidy/mopidy.conf:/etc/mopidy/mopidySFX.conf”
But I don’t understand how mopidy can manage the 2 configs.
#!/bin/sh
### BEGIN INIT INFO
# Provides: mopidy
# Required-Start: $network $remote_fs
# Required-Stop: $network $remote_fs
# Should-Start: $named alsa-utils avahi dbus pulseaudio
# Should-Stop: $named alsa-utils avahi dbus pulseaudio
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Mopidy music server
### END INIT INFO
PATH=/sbin:/usr/sbin:/bin:/usr/bin
DESC="Mopidy music server"
NAME=mopidy
DAEMON=/usr/bin/mopidy
DAEMON_USER=mopidy
DAEMON_GROUP=audio
CONFIG_FILES="/usr/share/mopidy/conf.d:/etc/mopidy/mopidy.conf:/etc/mopidy/mopidySFX.conf"
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
# Exit if the package is not installed
[ -x $DAEMON ] || exit 0
# Read configuration variable file if present
[ -r /etc/default/$NAME ] && . /etc/default/$NAME
# Load the VERBOSE setting and other rcS variables
. /lib/init/vars.sh
# Define LSB log_* functions.
. /lib/lsb/init-functions
do_start()
{
if [ ! -d /var/cache/mopidy ]; then
mkdir -p /var/cache/mopidy
chown mopidy:audio /var/cache/mopidy
fi
start-stop-daemon --start --quiet --name $NAME --pidfile $PIDFILE \
In the startup log above , mopidySFX.conf is not shown and in Iris, I cannot connect to mopidySFX.
Lastly, I have set the mopidySFX config to deliver on port 6681 on http section. Can mopidy serve 2 different channels on 2 seperate ports?
Any thoughts are most welcome.
Thank you