I use a single database for my self-hosted applications and instead of giving Seafile root access to my database container, I’d like to create the database/user/pass that will be utilized by Seafile myself ahead of time and assign it to Seafile after creating the Docker container.
I’m in the same boat. I’m stuck on seafileltd/seafile (Seafile 6) which doesn’t require root access to the DB but seafileltd/seafile-mc (Seafile 7) does. Just like you, I’d prefer to have a single DB server container and point my various self-hosted applications at it. Applications should NOT need root access to the DB, it’s just a poor and insecure design.
It’s also irksome that docker users are second-class citizens and are stuck using much older versions of Seafile. It would be great if the Seafile team could continue their architecture journey and provide a proper containerized stack so that I can use my own DB and proxy containers. We’re closer with Seafile 7, at least I can run a dedicated memcached and mariadb container but the need for root access makes it a hard pass for me.
As I recently setup v9.0.1 in docker with a mariadb database backend, I was a little irked by the need to provide the root for the database. However, I noticed that it was only required for the purpose of creating the seafile specific database account. I use docker-compose, so once Seafile was up and running on a single node, I took root password out of the environment variables. At that point, Seafile has created it’s own login and is using that, stored in the configuration files.
I agree, it’s not ideal. But it is a way to get v9+ installed w/o permanently giving Seafile the root db password.