Files
core/run.sh
Ingo Oppermann 477243a38e Fix clean shutdown with docker kill
By using "docker kill" to stop the core it will bluntly stop the core. A
graceful shutdown will be be performed because it sends SIGKILL which
cannot be trapped.

The "docker kill --signal SIGINT" command should be used instead, but
this requires that the core is root process in the image. The run.sh
shell script process has to be replaced by the core process, otherwise
the SIGINT will not reach the core.
2023-09-21 14:01:28 +02:00

22 lines
548 B
Bash
Executable File

#!/bin/sh
# First run the import program. It will read the db.dir from the config file in order to
# find an old v1.json. This will be converted to the new db format.
./bin/import
if [ $? -ne 0 ]; then
exit 1
fi
# Run the FFmpeg migration program. In case a FFmpeg 5 binary is present, it will create a
# backup of the current DB and modify the FFmpeg parameter such that they are compatible
# with FFmpeg 5.
./bin/ffmigrate
if [ $? -ne 0 ]; then
exit 1
fi
# Now run the core with the possibly converted configuration.
exec ./bin/core