{ config, lib, ... }: with lib; let moduleCfg = config.selfhosted.seafile; in { config = mkIf moduleCfg.enable { sops.templates."seadoc.env".content = '' DB_HOST=${moduleCfg.mariadb.name} DB_PORT=3306 DB_USER=seafile DB_PASSWORD=${config.sops.placeholder."seafile/mysql_password"} DB_NAME=seahub_db TIME_ZONE=${config.time.timeZone} JWT_PRIVATE_KEY=${config.sops.placeholder."seafile/jwt_private_key"} NON_ROOT=false SEAHUB_SERVICE_URL=http://${moduleCfg.server.name} ''; }; }