Skip to content

Commit

Permalink
Merge pull request #938 from olliewalsh/cn_length
Browse files Browse the repository at this point in the history
[dataplane] Use short hostname for CommonName in node cert
  • Loading branch information
openshift-merge-bot[bot] authored Jul 16, 2024
2 parents 74299b8 + 2167e47 commit cc1b75c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/dataplane/cert.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,8 +170,10 @@ func EnsureTLSCerts(ctx context.Context, helper *helper.Helper,
nodeName)
}

commonName := strings.Split(baseName, ".")[0]

certSecret, result, err = GetTLSNodeCert(ctx, helper, instance, certName,
issuer, labels, baseName, hosts, ips, service.Spec.TLSCerts[certKey].KeyUsages)
issuer, labels, commonName, hosts, ips, service.Spec.TLSCerts[certKey].KeyUsages)

// handle cert request errors
if (err != nil) || (result != ctrl.Result{}) {
Expand Down

0 comments on commit cc1b75c

Please sign in to comment.