Skip to content

Commit 02bf3cc

Browse files
committed
move ssh pub keys out of clab config tree
1 parent 771caa4 commit 02bf3cc

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

clab/export_templates/auto.tmpl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
"clab": {
55
"config": {
66
"prefix": "{{ .Clab.Config.Prefix }}",
7-
"mgmt": {{ ToJSONPretty .Clab.Config.Mgmt " " " "}},
8-
"ssh-pub-keys": {{ ToJSON .SSHPubKeys }}
7+
"mgmt": {{ ToJSONPretty .Clab.Config.Mgmt " " " "}}
98
}
109
},
10+
"ssh-pub-keys": {{ ToJSON .SSHPubKeys }},
1111
"nodes": { {{- $i:=0 }}{{range $n, $c := .NodeConfigs}}{{if $i}},{{end}}
1212
"{{$n}}": {
1313
"index": "{{$c.Index}}",

clab/export_templates/full.tmpl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"name": "{{ .Name }}",
33
"type": "{{ .Type }}",
44
"clab": {{ ToJSONPretty .Clab " " " "}},
5+
"ssh-pub-keys": {{ ToJSON .SSHPubKeys }},
56
"nodes": { {{- $i:=0 }}{{range $n, $c := .NodeConfigs}}{{if $i}},{{end}}{{ $k := dict "tls-key" $c.TLSKey }}
67
"{{$n}}":{{ $cj := $c | data.ToJSON | data.JSON }} {{ $dst := coll.Merge $cj $k }}{{ ToJSONPretty $dst " " " " }}{{$i = add $i 1}}{{end}}
78
},

0 commit comments

Comments
 (0)