diff --git a/modules/services/bar-assistant/default.nix b/modules/services/bar-assistant/default.nix index a631753..c5e7850 100644 --- a/modules/services/bar-assistant/default.nix +++ b/modules/services/bar-assistant/default.nix @@ -3,6 +3,7 @@ let in { lib, + inputs, config, ... }: { @@ -40,7 +41,7 @@ in extraConfig = '' allow 192.168.0.0/16; allow 10.8.0.0/24; - allow 172.220.132.255; + allow ${inputs.nix-secrets.network.primary.publicIP} deny all; ''; forceSSL = true; @@ -106,4 +107,3 @@ in }; }; } - diff --git a/modules/services/homebox/default.nix b/modules/services/homebox/default.nix index a4b80d3..2617f45 100644 --- a/modules/services/homebox/default.nix +++ b/modules/services/homebox/default.nix @@ -1,8 +1,4 @@ -{ - lib, - config, - ... -}: { +{inputs, ...}: { services = { nginx = { enable = true; @@ -15,7 +11,7 @@ extraConfig = '' allow 192.168.0.0/16; allow 10.8.0.0/24; - allow 172.220.132.255; + allow ${inputs.nix-secrets.network.primary.publicIP} deny all; ''; proxyPass = "http://localhost:7745"; diff --git a/modules/services/homepage/default.nix b/modules/services/homepage/default.nix index 8121135..eae93a6 100644 --- a/modules/services/homepage/default.nix +++ b/modules/services/homepage/default.nix @@ -2,25 +2,25 @@ lib, inputs, config, + pkgs, ... }: let s = inputs.nix-secrets; in { # Homepage.dev secrets sops = { - secrets = { - "homepage/openmeteo/lat" = {}; - "homepage/openmeteo/long" = {}; - "lubelogger/user" = {}; - "lubelogger/pass" = {}; - }; + #secrets = { + #"lubelogger/user" = {}; + #"lubelogger/pass" = {}; + #}; templates."homepage-environment".content = '' - HOMEPAGE_VAR_LAT = ${config.sops.placeholder."homepage/openmeteo/lat"} - HOMEPAGE_VAR_LONG = ${config.sops.placeholder."homepage/openmeteo/long"} - HOMEPAGE_VAR_LUBELOGGERUSER = ${config.sops.placeholder."lubelogger/user"} - HOMEPAGE_VAR_LUBELOGGERPASS = ${config.sops.placeholder."lubelogger/pass"} + HOMEPAGE_VAR_LAT = ${s.crow.location.lat} + HOMEPAGE_VAR_LONG = ${s.crow.location.long} HOMEPAGE_ALLOWED_HOSTS = home.wanderingcrow.net ''; + #Need to put these back in later + #HOMEPAGE_VAR_LUBELOGGERUSER = ${config.sops.placeholder."lubelogger/user"} + #HOMEPAGE_VAR_LUBELOGGERPASS = ${config.sops.placeholder."lubelogger/pass"} }; services.nginx = { @@ -33,8 +33,7 @@ in { locations."/" = { extraConfig = '' allow 192.168.0.0/16; - allow 10.8.0.0/24; - allow 172.220.134.108; + allow ${s.network.primary.publicIP} deny all; ''; proxyPass = "http://localhost:8089"; @@ -63,8 +62,8 @@ in { widget = { type = "lubelogger"; url = "https://garage.wanderingcrow.net"; - username = "{{HOMEPAGE_VAR_LUBELOGGERUSER}}"; - password = "{{HOMEPAGE_VAR_LUBELOGGERPASS}}"; + # username = "{{HOMEPAGE_VAR_LUBELOGGERUSER}}"; + # password = "{{HOMEPAGE_VAR_LUBELOGGERPASS}}"; }; }; } @@ -185,42 +184,7 @@ in { } ]; } - { - Work = [ - { - Jira = [ - { - icon = "jira.svg"; - href = "https://home.atlassian.com/"; - } - ]; - } - { - AWS = [ - { - icon = "aws.svg"; - href = "https://console.aws.amazon.com/"; - } - ]; - } - { - Email = [ - { - icon = "gmail.svg"; - href = "https://mail.google.com/mail/u/1/#inbox"; - } - ]; - } - { - Groups = [ - { - icon = "https://www.gstatic.com/images/branding/product/1x/groups_32dp.png"; - href = "https://groups.google.com/u/1/"; - } - ]; - } - ]; - } + s.work.homepage { Nix = [ { diff --git a/modules/services/openhab/default.nix b/modules/services/openhab/default.nix index 73dac62..351cfe6 100644 --- a/modules/services/openhab/default.nix +++ b/modules/services/openhab/default.nix @@ -4,6 +4,7 @@ in { lib, config, + inputs, ... }: { systemd.tmpfiles.rules = [ @@ -40,7 +41,7 @@ in extraConfig = '' allow 192.168.0.0/16; allow 10.8.0.0/24; - allow 172.220.132.255; + allow ${inputs.nix-secrets.network.primary.publicIP} deny all; ''; proxyPass = "http://10.88.0.9:8080";