|
|
|
@ -754,13 +754,17 @@ func provisionerOptionsToLinkedca(p *provisioner.Options) (*linkedca.Template, *
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if p.X509.Template != "" {
|
|
|
|
|
x509Template.Template = []byte(p.SSH.Template)
|
|
|
|
|
x509Template.Template = []byte(p.X509.Template)
|
|
|
|
|
} else if p.X509.TemplateFile != "" {
|
|
|
|
|
filename := step.Abs(p.X509.TemplateFile)
|
|
|
|
|
if x509Template.Template, err = os.ReadFile(filename); err != nil {
|
|
|
|
|
return nil, nil, nil, errors.Wrap(err, "error reading x509 template")
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if p.X509.TemplateData != nil {
|
|
|
|
|
x509Template.Data = p.X509.TemplateData
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if p.SSH != nil && p.SSH.HasTemplate() {
|
|
|
|
@ -777,6 +781,10 @@ func provisionerOptionsToLinkedca(p *provisioner.Options) (*linkedca.Template, *
|
|
|
|
|
return nil, nil, nil, errors.Wrap(err, "error reading ssh template")
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if p.SSH.TemplateData != nil {
|
|
|
|
|
sshTemplate.Data = p.SSH.TemplateData
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var webhooks []*linkedca.Webhook
|
|
|
|
|