Use of [centos image](https://hub.docker.com/_/centos) as base image as it offer the possibility to use systemd.
In order to run systemd in a container it has to run in privileged mode and bind to the `cgroup` of the host.
## Image
In addition to the base image, there is the compilation of ffmpeg and all lib from source based on https://github.com/jrottenberg/ffmpeg.
We can't use directly the image from `jrottenberg/ffmpeg` as it compile ffmpeg with the flag `--enable-small` that remove some part of the json from the ffprobe command.
There is also a conf file to override the ffplayout.service as the libs for ffmpeg are not in the defauft place which is copied to `/etc/systemd/system/ffplayout.service.d/overide.conf`.
The image is build with a default user/pass `admin/admin`.
You can take a look à the [Dockerfile](Dockerfile)
### /!\ as ffmpeg is compiled with `--enable-nonfree` don't push it to a public registry nor distribute the image /!\
## Storage
There are some folders/files that are important for ffplayout to work well such as :
- /usr/share/ffplayout/db => where all the data for the `ffpapi` are stored (user/pass etc)
- /var/lib/ffplayout/tv-media => where the media are stored by default (configurable)
- /var/lib/ffplayout/playlists => where playlists are stored (configurable)
- /etc/ffplayout/ffplayout.yml => the core config file
It may be useful to create/link volume for those folders/files.