Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion pkg/internal/testing/controlplane/apiserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,11 @@ func (s *APIServer) populateAPIServerCerts() error {
return err
}

servingCerts, err := ca.NewServingCert()
certNames := []string{"localhost"}
if len(s.SecureServing.Address) > 0 {
certNames = append(certNames, s.SecureServing.Address)
}
servingCerts, err := ca.NewServingCert(certNames...)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only even when no certnames are passed to ca.NewServingCert(), localhost is getting added by default. Do we modify the condition in pkg/internal/testing/certs/tinyca.go instead of here?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would also be possible, of course. Should I implement this or is it a consideration for now?

if err != nil {
return err
}
Expand Down