mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-03-23 17:48:28 +01:00
Compare commits
No commits in common. "ed070e6abe7f70d59ba570474dd8de43224fcb55" and "b94ff46b241e2620860799b1b291cbb2ad05cdcc" have entirely different histories.
ed070e6abe
...
b94ff46b24
4 changed files with 10 additions and 17 deletions
|
|
@ -29,8 +29,8 @@ _: {
|
|||
packages = [
|
||||
pkgs.nebula
|
||||
pkgs.bitwarden-cli
|
||||
self'.packages.nebula-recert-host
|
||||
self'.packages.nebula-recert-all-hosts
|
||||
self'.packages.nebula-regen-host-cert
|
||||
self'.packages.nebula-regen-all-host-certs
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
|
|
|
|||
|
|
@ -10,16 +10,9 @@
|
|||
{
|
||||
packages =
|
||||
"${self}/scripts"
|
||||
|> lib.filesystem.listFilesRecursive
|
||||
|> lib.map (file: {
|
||||
name =
|
||||
file
|
||||
|> lib.unsafeDiscardStringContext
|
||||
|> lib.removePrefix "${self}/scripts/"
|
||||
|> lib.removeSuffix ".nix"
|
||||
|> lib.replaceString "/" "-";
|
||||
value = import file { inherit self' pkgs lib; };
|
||||
})
|
||||
|> lib.listToAttrs;
|
||||
|> builtins.readDir
|
||||
|> lib.attrNames
|
||||
|> lib.map (name: name |> lib.removeSuffix ".nix")
|
||||
|> self.lib.genAttrs (name: import "${self}/scripts/${name}.nix" { inherit self' pkgs lib; });
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
{ self', pkgs, ... }:
|
||||
pkgs.writeShellApplication {
|
||||
name = "nebula-recert-all-hosts";
|
||||
name = "nebula-regen-all-host-certs";
|
||||
|
||||
runtimeInputs = [
|
||||
pkgs.bitwarden-cli
|
||||
pkgs.jq
|
||||
self'.packages.nebula-recert-host
|
||||
self'.packages.nebula-regen-host-cert
|
||||
];
|
||||
|
||||
text = ''
|
||||
|
|
@ -23,7 +23,7 @@ pkgs.writeShellApplication {
|
|||
|
||||
for host in $hosts; do
|
||||
echo "Regenerating certificate for $host..."
|
||||
nebula-recert-host "$host" "$ca_key"
|
||||
nebula-regen-host-cert "$host" "$ca_key"
|
||||
done
|
||||
|
||||
echo "Done!"
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
{ pkgs, ... }:
|
||||
pkgs.writeShellApplication {
|
||||
name = "nebula-recert-host";
|
||||
name = "nebula-regen-host-cert";
|
||||
|
||||
runtimeInputs = [
|
||||
pkgs.nebula
|
||||
Loading…
Add table
Add a link
Reference in a new issue