Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

provide client certs to servicemonitor CRDs #687

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
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
14 changes: 13 additions & 1 deletion charts/redpanda/templates/servicemonitor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,22 @@ spec:
scheme: https
tlsConfig:
insecureSkipVerify: true
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we skip this if we are applying the certs?

Copy link
Author

Choose a reason for hiding this comment

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

It makes HTTPS request to IP address (without hostname) and check SANs for the certificate (and it does not match)

ca:
Copy link
Contributor

Choose a reason for hiding this comment

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

Only if CA is enabled right? That is an option in the certs stanza of the values file.

secret:
name: {{ template "redpanda.fullname" $ }}-default-cert
Copy link
Contributor

Choose a reason for hiding this comment

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

This is the default name in most cases, but not necessarily, we should check to see if a secret is being provided instead also.

key: ca.crt
cert:
secret:
name: {{ template "redpanda.fullname" $ }}-default-cert
key: tls.crt
key:
secret:
name: {{ template "redpanda.fullname" $ }}-default-cert
key: tls.key
{{- end }}
selector:
matchLabels:
monitoring.redpanda.com/enabled: "true"
app.kubernetes.io/name: {{ template "redpanda.name" . }}
app.kubernetes.io/instance: {{ .Release.Name | quote }}
{{- end }}
{{- end }}