dotfiles/provision/hosts/torus/nextcloud.nix

52 lines
1.2 KiB
Nix
Raw Normal View History

2024-05-21 21:53:08 -07:00
{ config, lib, pkgs, user, ... }:
{
environment.systemPackages = with pkgs; [
cron
];
# nextcloud secrets
age.secrets."nextcloud/password" = {
2024-07-21 16:37:12 -07:00
file = ../../secrets/nextcloud/password.age;
owner = "nextcloud";
group = "nextcloud";
};
2024-05-21 21:53:08 -07:00
services = {
nginx.virtualHosts = {
"cloud.tstarr.us" = {
forceSSL = true;
enableACME = true;
};
};
nextcloud = {
enable = true;
hostName = "cloud.tstarr.us";
# Need to manually increment with every major upgrade.
package = pkgs.nextcloud29;
# Let NixOS install and configure the database automatically.
database.createLocally = true;
# Let NixOS install and configure Redis caching automatically.
configureRedis = true;
# Increase the maximum file upload size to avoid problems uploading videos.
maxUploadSize = "16G";
https = true;
autoUpdateApps.enable = true;
settings = {
overwriteprotocol = "https";
default_phone_region = "US";
};
config = {
dbtype = "mysql";
adminuser = "admin";
adminpassFile = "/run/agenix/nextcloud/password";
2024-05-21 21:53:08 -07:00
};
};
};
}