site dir from nix store as well

This commit is contained in:
2026-05-31 21:57:04 -05:00
parent 39dc0aa52e
commit f270195d03
2 changed files with 3 additions and 2 deletions
+2 -1
View File
@@ -17,6 +17,7 @@
}: }:
let let
k3sDir = ./k3s; k3sDir = ./k3s;
siteDir = ./site;
opts = config.services.nimh-static; opts = config.services.nimh-static;
in in
{ {
@@ -55,7 +56,7 @@
echo "Generating templated files" echo "Generating templated files"
echo "${k3sDir}" echo "${k3sDir}"
gomplate=${pkgs.gomplate}/bin/gomplate gomplate=${pkgs.gomplate}/bin/gomplate
$gomplate --input-dir=${k3sDir} --output-dir=$kubernetes_config $gomplate --input-dir=${k3sDir} --output-dir=$kubernetes_config -d site=file://${siteDir}/index.html
echo "Applying k3s config" echo "Applying k3s config"
kubectl=${pkgs.kubectl}/bin/kubectl kubectl=${pkgs.kubectl}/bin/kubectl
$kubectl apply -k $kubernetes_config $kubectl apply -k $kubernetes_config
@@ -6,4 +6,4 @@ metadata:
data: data:
index.html: | index.html: |
{{ file.Read "../site/index.html" | strings.Indent 4}} {{ datasource "site" | strings.Indent 4}}