alpha
Login
or
Join now
hermes.pds.lassul.us
/
superconfig
forked from
lass.pds.lassul.us/superconfig
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
This repository has no description
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
retilum: migrate from facts to vars
author
lassulus
date
2 years ago
(Dec 11, 2024, 10:45 PM CET)
commit
4c6e4ea5
4c6e4ea503da51ed51f2fe32309029a330b6cc25
parent
507849bf
507849bfcac80536c65d5fd66e6e75d2b1bd277c
+15
-14
1 changed file
Expand all
Collapse all
Unified
Split
2configs
retiolum.nix
+15
-14
2configs/retiolum.nix
View file
Reviewed
···
17
17
AutoConnect = yes
18
18
LocalDiscovery = yes
19
19
'';
20
20
-
privkey = config.clanCore.facts.services.retiolum.secret."retiolum.rsa_key.priv".path;
21
21
-
privkey_ed25519 = config.clanCore.facts.services.retiolum.secret."retiolum.ed25519_key.priv".path;
20
20
+
privkey = config.clan.core.vars.generators.retiolum.files."retiolum.rsa_key.priv".path;
21
21
+
privkey_ed25519 = config.clan.core.vars.generators.retiolum.files."retiolum.ed25519_key.priv".path;
22
22
};
23
23
24
24
-
clanCore.facts.services.retiolum = {
25
25
-
secret."retiolum.rsa_key.priv" = { };
26
26
-
secret."retiolum.ed25519_key.priv" = { };
27
27
-
public."retiolum.rsa_key.pub" = { };
28
28
-
public."retiolum.ed25519_key.pub" = { };
29
29
-
generator.path = with pkgs; [
24
24
+
clanCore.vars.generators.retiolum = {
25
25
+
files."retiolum.rsa_key.priv" = { };
26
26
+
files."retiolum.ed25519_key.priv" = { };
27
27
+
files."retiolum.rsa_key.pub".secret = false;
28
28
+
files."retiolum.ed25519_key.pub".secret = false;
29
29
+
migrateFact = "retiolum";
30
30
+
runtimeInputs = with pkgs; [
30
31
coreutils
31
32
tinc_pre
32
33
];
33
33
-
generator.script = ''
34
34
-
tinc --config "$secrets" generate-keys 4096 >/dev/null
35
35
-
mv "$secrets"/rsa_key.priv "$secrets"/retiolum.rsa_key.priv
36
36
-
mv "$secrets"/ed25519_key.priv "$secrets"/retiolum.ed25519_key.priv
37
37
-
mv "$secrets"/rsa_key.pub "$facts"/retiolum.rsa_key.pub
38
38
-
mv "$secrets"/ed25519_key.pub "$facts"/retiolum.ed25519_key.pub
34
34
+
script = ''
35
35
+
tinc --config "$out" generate-keys 4096 >/dev/null
36
36
+
mv "$out"/rsa_key.priv "$out"/retiolum.rsa_key.priv
37
37
+
mv "$out"/ed25519_key.priv "$out"/retiolum.ed25519_key.priv
38
38
+
mv "$out"/rsa_key.pub "$out"/retiolum.rsa_key.pub
39
39
+
mv "$out"/ed25519_key.pub "$out"/retiolum.ed25519_key.pub
39
40
'';
40
41
};
41
42