rest of mailserver
This commit is contained in:
parent
0b8e88f09d
commit
d89757afb9
@ -1,52 +0,0 @@
|
||||
{ pkgs, ... }: {
|
||||
|
||||
fileSystems."/mnt/export1981" = {
|
||||
device = "172.16.128.47:/nas/5490";
|
||||
fsType = "nfs";
|
||||
options = [ "nofail" ];
|
||||
};
|
||||
|
||||
users = {
|
||||
users.ivand = {
|
||||
isNormalUser = true;
|
||||
hashedPassword =
|
||||
"$2b$05$hPrPcewxj4qjLCRQpKBAu.FKvKZdIVlnyn4uYsWE8lc21Jhvc9jWG";
|
||||
extraGroups = [ "wheel" "adm" "mlocate" ];
|
||||
openssh.authorizedKeys.keys = [
|
||||
''
|
||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICcLkzuCoBEg+wq/H+hkrv6pLJ8J5BejaNJVNnymlnlo ivan@idimitrov.dev
|
||||
''
|
||||
];
|
||||
};
|
||||
extraGroups = { mlocate = { }; };
|
||||
};
|
||||
|
||||
services = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
settings = {
|
||||
PermitRootLogin = "prohibit-password";
|
||||
};
|
||||
};
|
||||
};
|
||||
systemd = {
|
||||
timers = {
|
||||
bingwp = {
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
OnCalendar = "*-*-* 10:00:00";
|
||||
Persistent = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
services = {
|
||||
bingwp = {
|
||||
description = "Download bing image of the day";
|
||||
script = ''
|
||||
${pkgs.nushell}/bin/nu -c "http get ('https://bing.com' + ((http get https://www.bing.com/HPImageArchive.aspx?format=js&n=1).images.0.url)) | save ('/var/pic' | path join ( [ (date now | format date '%Y-%m-%d'), '.png' ] | str join ))"
|
||||
${pkgs.nushell}/bin/nu -c "${pkgs.toybox}/bin/ln -sf (ls /var/pic | where type == file | get name | sort | last) /var/pic/latest.png"
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
@ -22,7 +22,7 @@ in
|
||||
nova-nonya = novaConfig (with mods; [ ivand anon cryptocurrency ]);
|
||||
nova-ai = novaConfig (with mods; [ ivand ai ]);
|
||||
install-iso = configWithModules { modules = (with mods; [ grub base shell wireless ]); };
|
||||
vps = configWithModules { modules = (with mods; [ base shell security vps mailserver nginx wireguard-output anonymous-dns firewall ]); };
|
||||
vps = configWithModules { modules = (with mods; [ base shell security vps mailserver nginx wireguard-output anonymous-dns firewall rest ]); };
|
||||
stara-miner = configWithModules { modules = (essential ++ [ mods.monero-miner ]); };
|
||||
};
|
||||
}
|
||||
|
@ -252,7 +252,6 @@ top@{ inputs, moduleWithSystem, ... }: {
|
||||
vps = moduleWithSystem (toplevel@{ ... }: perSystem@{ ... }: {
|
||||
imports = [
|
||||
inputs.vpsadminos.nixosConfigurations.container
|
||||
../../hosts/vps/mailserver
|
||||
];
|
||||
});
|
||||
mailserver = moduleWithSystem (toplevel@{ ... }: perSystem@{ config, pkgs, ... }: {
|
||||
@ -517,5 +516,54 @@ top@{ inputs, moduleWithSystem, ... }: {
|
||||
};
|
||||
};
|
||||
});
|
||||
rest = moduleWithSystem (toplevel@{ ... }: perSystem@{ pkgs, ... }: {
|
||||
fileSystems."/mnt/export1981" = {
|
||||
device = "172.16.128.47:/nas/5490";
|
||||
fsType = "nfs";
|
||||
options = [ "nofail" ];
|
||||
};
|
||||
users = {
|
||||
users.ivand = {
|
||||
isNormalUser = true;
|
||||
hashedPassword =
|
||||
"$2b$05$hPrPcewxj4qjLCRQpKBAu.FKvKZdIVlnyn4uYsWE8lc21Jhvc9jWG";
|
||||
extraGroups = [ "wheel" "adm" "mlocate" ];
|
||||
openssh.authorizedKeys.keys = [
|
||||
''
|
||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICcLkzuCoBEg+wq/H+hkrv6pLJ8J5BejaNJVNnymlnlo ivan@idimitrov.dev
|
||||
''
|
||||
];
|
||||
};
|
||||
extraGroups = { mlocate = { }; };
|
||||
};
|
||||
services = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
settings = {
|
||||
PermitRootLogin = "prohibit-password";
|
||||
};
|
||||
};
|
||||
};
|
||||
systemd = {
|
||||
timers = {
|
||||
bingwp = {
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
OnCalendar = "*-*-* 10:00:00";
|
||||
Persistent = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
services = {
|
||||
bingwp = {
|
||||
description = "Download bing image of the day";
|
||||
script = ''
|
||||
${pkgs.nushell}/bin/nu -c "http get ('https://bing.com' + ((http get https://www.bing.com/HPImageArchive.aspx?format=js&n=1).images.0.url)) | save ('/var/pic' | path join ( [ (date now | format date '%Y-%m-%d'), '.png' ] | str join ))"
|
||||
${pkgs.nushell}/bin/nu -c "${pkgs.toybox}/bin/ln -sf (ls /var/pic | where type == file | get name | sort | last) /var/pic/latest.png"
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
});
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user