dotfiles/hosts/hitsugibune/nextcloud.nix

44 lines
1 KiB
Nix

{
config,
pkgs,
lib,
...
}: {
# This is only a temporary password and will be changed
environment.etc."nextcloud-admin-pass".text = "samcsamc11";
networking.firewall.allowedTCPPorts = [80 443];
services.nextcloud = {
enable = true;
hostName = "nextcloud.sprechtl.me";
https = true;
configureRedis = true;
caching.redis = true;
autoUpdateApps.enable = true;
package = pkgs.nextcloud31;
config = {
adminuser = "admin";
adminpassFile = "/etc/nextcloud-admin-pass";
dbtype = "pgsql";
};
database.createLocally = true;
};
services.nginx = {
enable = true;
recommendedGzipSettings = true;
recommendedOptimisation = true;
recommendedProxySettings = true;
recommendedTlsSettings = true;
virtualHosts.${config.services.nextcloud.hostName} = {
forceSSL = true;
enableACME = true;
};
};
security.acme = {
acceptTerms = true;
certs = {
${config.services.nextcloud.hostName}.email = "stefan@tague.at";
};
};
}