forked from TrueCloudLab/certificates
Add SSHPOP default provisioner if SSH enabled during init
This commit is contained in:
parent
3f844c5e23
commit
3fb116f1b4
1 changed files with 10 additions and 0 deletions
10
pki/pki.go
10
pki/pki.go
|
@ -446,9 +446,19 @@ func (p *PKI) GenerateConfig(opt ...Option) (*authority.Config, error) {
|
||||||
HostKey: p.sshHostKey,
|
HostKey: p.sshHostKey,
|
||||||
UserKey: p.sshUserKey,
|
UserKey: p.sshUserKey,
|
||||||
}
|
}
|
||||||
|
// Enable SSH authorization for default JWK provisioner
|
||||||
prov.Claims = &provisioner.Claims{
|
prov.Claims = &provisioner.Claims{
|
||||||
EnableSSHCA: &enableSSHCA,
|
EnableSSHCA: &enableSSHCA,
|
||||||
}
|
}
|
||||||
|
// Add default SSHPOP provisioner
|
||||||
|
sshpop := &provisioner.SSHPOP{
|
||||||
|
Type: "SSHPOP",
|
||||||
|
Name: "sshpop",
|
||||||
|
Claims: &provisioner.Claims{
|
||||||
|
EnableSSHCA: &enableSSHCA,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
config.AuthorityConfig.Provisioners = append(config.AuthorityConfig.Provisioners, sshpop)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Apply configuration modifiers
|
// Apply configuration modifiers
|
||||||
|
|
Loading…
Reference in a new issue