fix vaultwarden domain
this makes vaultwarden send downloads work correctly
This commit is contained in:
parent
02385086ff
commit
b10a2331c4
3 changed files with 10 additions and 3 deletions
|
@ -15,10 +15,12 @@
|
||||||
systems = ["x86_64-linux"];
|
systems = ["x86_64-linux"];
|
||||||
|
|
||||||
flake.nixosConfigurations = mylib.loadConfigurations ./sys/machines (hostname: {
|
flake.nixosConfigurations = mylib.loadConfigurations ./sys/machines (hostname: {
|
||||||
inherit inputs self systemProfiles homeProfiles homeSuites vars;
|
inherit inputs self systemProfiles homeProfiles homeSuites vars mylib;
|
||||||
hostVars = ./vars/${hostname};
|
hostVars = ./vars/${hostname};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
flake._mylib = mylib;
|
||||||
|
|
||||||
perSystem = {pkgs, ...}: {
|
perSystem = {pkgs, ...}: {
|
||||||
imports = [
|
imports = [
|
||||||
./shells
|
./shells
|
||||||
|
|
|
@ -7,4 +7,5 @@ in {
|
||||||
modules = [(dir + /${name})];
|
modules = [(dir + /${name})];
|
||||||
specialArgs = specialArgsFromHost name;
|
specialArgs = specialArgsFromHost name;
|
||||||
})) (b.readDir dir);
|
})) (b.readDir dir);
|
||||||
|
stripPort = url: builtins.match "(.*):[0-9]*" url |> builtins.head;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,8 @@
|
||||||
{config, ...}: {
|
{
|
||||||
|
config,
|
||||||
|
mylib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
systemd.services.vaultwarden = {
|
systemd.services.vaultwarden = {
|
||||||
serviceConfig.EnvironmentFile = config.sops.secrets.vaultwarden-env.path;
|
serviceConfig.EnvironmentFile = config.sops.secrets.vaultwarden-env.path;
|
||||||
};
|
};
|
||||||
|
@ -6,7 +10,7 @@
|
||||||
services.vaultwarden = {
|
services.vaultwarden = {
|
||||||
enable = true;
|
enable = true;
|
||||||
config = {
|
config = {
|
||||||
DOMAIN = "https://${config.services.caddy.virtualHosts.vaultwarden.hostName}";
|
DOMAIN = mylib.stripPort "https://${config.services.caddy.virtualHosts.vaultwarden.hostName}";
|
||||||
ROCKET_ADDRESS = "0.0.0.0";
|
ROCKET_ADDRESS = "0.0.0.0";
|
||||||
ROCKET_PORT = 35381;
|
ROCKET_PORT = 35381;
|
||||||
ROCKET_LOG = "critical";
|
ROCKET_LOG = "critical";
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue