mirror of
https://git.sr.ht/~rouven/nixos-config
synced 2025-05-13 15:51:09 +02:00
caddy: make a shared module
This commit is contained in:
parent
ff44839229
commit
f511f7d146
6 changed files with 53 additions and 42 deletions
24
shared/caddy/default.nix
Normal file
24
shared/caddy/default.nix
Normal file
|
@ -0,0 +1,24 @@
|
|||
{ config, ... }:
|
||||
{
|
||||
services.caddy = {
|
||||
enable = true;
|
||||
email = "ca@${config.networking.domain}";
|
||||
logFormat = "format console";
|
||||
globalConfig = ''
|
||||
servers {
|
||||
metrics
|
||||
}
|
||||
'';
|
||||
virtualHosts.":2018" = {
|
||||
extraConfig = ''
|
||||
metrics
|
||||
'';
|
||||
logFormat = ''
|
||||
output discard
|
||||
'';
|
||||
};
|
||||
};
|
||||
systemd.services.caddy.environment.XDG_DATA_HOME = "/var/lib";
|
||||
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
||||
networking.firewall.allowedUDPPorts = [ 443 ];
|
||||
}
|
|
@ -26,6 +26,8 @@ in
|
|||
iperf
|
||||
jq
|
||||
helix
|
||||
nushell
|
||||
atuin
|
||||
];
|
||||
users.defaultUserShell = pkgs.zsh;
|
||||
programs.fzf = {
|
||||
|
@ -68,6 +70,8 @@ in
|
|||
zstyle ':completion:*:complete:networkctl:*' list-grouped true
|
||||
source ${pkgs.agdsn-zsh-config}/etc/zsh/zshrc
|
||||
source ${pkgs.zsh-fzf-tab}/share/fzf-tab/fzf-tab.plugin.zsh
|
||||
source ${pkgs.zsh-vi-mode}/share/zsh-vi-mode/zsh-vi-mode.plugin.zsh
|
||||
zvm_after_init_commands+=(eval "$(atuin init zsh)")
|
||||
unsetopt extendedglob
|
||||
|
||||
|
||||
|
@ -100,7 +104,6 @@ in
|
|||
# then
|
||||
# cat ${../images/cat.sixel}
|
||||
# fi
|
||||
eval "$(${pkgs.mcfly}/bin/mcfly init zsh)"
|
||||
eval "$(${pkgs.zoxide}/bin/zoxide init zsh)"
|
||||
'';
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue