BIG changes. Make almost every server service modular, to distribute among multiple servers
This commit is contained in:
parent
30fc0dc800
commit
7e40fd4fb3
44 changed files with 153 additions and 143 deletions
|
@ -6,5 +6,5 @@
|
|||
./simplenix
|
||||
];
|
||||
|
||||
options.system.mailserver.enable = lib.mkEnableOption "Enable Simple NixOS Mailserver";
|
||||
options.services.mailserver.enable = lib.mkEnableOption "Enable Simple NixOS Mailserver";
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
imports = [ ./nginx ];
|
||||
|
||||
services.go-autoconfig = {
|
||||
enable = config.system.mailserver.enable;
|
||||
enable = config.services.mailserver.enable;
|
||||
settings = {
|
||||
service_addr = ":1323";
|
||||
domain = "autoconfig.nixfox.ca";
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{ config, lib, ... }:
|
||||
{
|
||||
services.nginx.virtualHosts."autoconfig.nixfox.ca" = lib.mkIf config.mailserver.enable {
|
||||
services.nginx.virtualHosts."autoconfig.nixfox.ca" = lib.mkIf config.services.go-autoconfig.enable {
|
||||
enableACME = true;
|
||||
forceSSL = true;
|
||||
locations."/" = {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{ config, lib, ... }:
|
||||
{
|
||||
config = lib.mkIf config.system.mailserver.enable {
|
||||
config = lib.mkIf config.services.mailserver.enable {
|
||||
services.roundcube = {
|
||||
enable = true;
|
||||
hostName = "mail.nixfox.ca";
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
mailserver.nixosModule
|
||||
];
|
||||
|
||||
config = lib.mkIf config.system.mailserver.enable {
|
||||
config = lib.mkIf config.services.mailserver.enable {
|
||||
mailserver = {
|
||||
enable = true;
|
||||
domains = [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue