You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 16, 2023. It is now read-only.
Kubernetes provider: E.g. GKE (Google Kubernetes Engine)
bare-metal
Describe the bug:
Followning the official example results in error about DNS-1123
kubectl create secret generic slack_hook --from-literal=xpack.notification.slack.account.monitoring.secure_url='https://hooks.slack.com/services/asdasdasd/asdasdas/asdasd'
The Secret "slack_hook" is invalid: metadata.name: Invalid value: "slack_hook": a DNS-1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*')
Steps to reproduce:
create a secret with an underscore in it's name
view the error
Expected behavior:
To be able to create secrets for the snapshotting plugins (many of which have an underscore in their name) as in here:
Hi @joshuacox,
Thanks for reporting this issue.
It seems that k8s don't accept _ in secrets name.
I guess this was working in previous k8s versions when we added this example to the doc, but k8s behavior changed since.
You can fix it by naming your secret slack-hook instead of slack_hook:
$ kubectl create secret generic slack_hook --from-literal=xpack.notification.slack.account.monitoring.secure_url='https://hooks.slack.com/services/asdasdasd/asdasdas/asdasd'
The Secret "slack_hook" is invalid: metadata.name: Invalid value: "slack_hook": a DNS-1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*')
$ kubectl create secret generic slack-hook --from-literal=xpack.notification.slack.account.monitoring.secure_url='https://hooks.slack.com/services/asdasdasd/asdasdas/asdasd'
secret/slack-hook created
Chart version:
Kubernetes version:
v1.18.6
Kubernetes provider: E.g. GKE (Google Kubernetes Engine)
bare-metal
Describe the bug:
Followning the official example results in error about DNS-1123
Steps to reproduce:
Expected behavior:
To be able to create secrets for the snapshotting plugins (many of which have an underscore in their name) as in here:
https://discuss.elastic.co/t/adding-credentials-to-helm-chart/242420/2
Provide logs and/or server output (if relevant):
This can also be duplicated in under three minutes here:
https://labs.play-with-k8s.com/
and here:
https://www.katacoda.com/thoth/scenarios/duplicatednserror
The text was updated successfully, but these errors were encountered: