Galley Configuration Problems

Seemingly valid configuration is rejected

Manually verify your configuration is correct, cross-referencingIstio API reference whennecessary.

Invalid configuration is accepted

Verify the istio-galley validationwebhookconfiguration exists andis correct. The apiVersion, apiGroup, and resource of theinvalid configuration should be listed in one of the two webhooksentries.

  1. $ kubectl get validatingwebhookconfiguration istio-galley -o yaml
  2. apiVersion: admissionregistration.k8s.io/v1beta1
  3. kind: ValidatingWebhookConfiguration
  4. metadata:
  5. labels:
  6. app: istio-galley
  7. name: istio-galley
  8. ownerReferences:
  9. - apiVersion: apps/v1
  10. blockOwnerDeletion: true
  11. controller: true
  12. kind: Deployment
  13. name: istio-galley
  14. uid: 5c64585d-91c6-11e8-a98a-42010a8001a8
  15. webhooks:
  16. - clientConfig:
  17. # caBundle should be non-empty. This is periodically (re)patched
  18. # every second by the webhook service using the ca-cert
  19. # from the mounted service account secret.
  20. caBundle: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUM1VENDQWMyZ0F3SUJBZ0lRVzVYNWpJcnJCemJmZFdLaWVoaVVSakFOQmdrcWhraUc5dzBCQVFzRkFEQWMKTVJvd0dBWURWUVFLRXhGck9ITXVZMngxYzNSbGNpNXNiMk5oYkRBZUZ3MHhPREEzTWpjeE56VTJNakJhRncweApPVEEzTWpjeE56VTJNakJhTUJ3eEdqQVlCZ05WQkFvVEVXczRjeTVqYkhWemRHVnlMbXh2WTJGc01JSUJJakFOCkJna3Foa2lHOXcwQkFRRUZBQU9DQVE4QU1JSUJDZ0tDQVFFQXdVMi9SdWlyeTNnUzdPd2xJRCtaaGZiOEpOWnMKK05OL0dRWUsxbVozb3duaEw4dnJHdDBhenpjNXFuOXo2ZEw5Z1pPVFJXeFVCYXVJMUpOa3d0dSt2NmRjRzlkWgp0Q2JaQWloc1BLQWQ4MVRaa3RwYkNnOFdrcTRyNTh3QldRemNxMldsaFlPWHNlWGtRejdCbStOSUoyT0NRbmJwCjZYMmJ4Slc2OGdaZkg2UHlNR0libXJxaDgvZ2hISjFha3ptNGgzc0VGU1dTQ1Y2anZTZHVJL29NM2pBem5uZlUKU3JKY3VpQnBKZmJSMm1nQm4xVmFzNUJNdFpaaTBubDYxUzhyZ1ZiaHp4bWhpeFhlWU0zQzNHT3FlRUthY0N3WQo0TVczdEJFZ3NoN2ovZGM5cEt1ZG1wdFBFdit2Y2JnWjdreEhhazlOdFV2YmRGempJeTMxUS9Qd1NRSURBUUFCCm95TXdJVEFPQmdOVkhROEJBZjhFQkFNQ0FnUXdEd1lEVlIwVEFRSC9CQVV3QXdFQi96QU5CZ2txaGtpRzl3MEIKQVFzRkFBT0NBUUVBTnRLSnVkQ3NtbTFzU3dlS2xKTzBIY1ZMQUFhbFk4ZERUYWVLNksyakIwRnl0MkM3ZUtGSAoya3JaOWlkbWp5Yk8xS0djMVlWQndNeWlUMGhjYWFlaTdad2g0aERRWjVRN0k3ZFFuTVMzc2taR3ByaW5idU1aCmg3Tm1WUkVnV1ZIcm9OcGZEN3pBNEVqWk9FZzkwR0J6YXUzdHNmanI4RDQ1VVRJZUw3M3hwaUxmMXhRTk10RWEKd0NSelplQ3lmSUhra2ZrTCtISVVGK0lWV1g2VWp2WTRpRDdRR0JCenpHZTluNS9KM1g5OU1Gb1F3bExjNHMrTQpnLzNQdnZCYjBwaTU5MWxveXluU3lkWDVqUG5ibDhkNEFJaGZ6OU8rUTE5UGVULy9ydXFRNENOancrZmVIbTBSCjJzYmowZDd0SjkyTzgwT2NMVDlpb05NQlFLQlk3cGlOUkE9PQotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0tCg==
  21. service:
  22. # service corresponds to the Kubernetes service that implements the
  23. # webhook, e.g. istio-galley.istio-system.svc:443
  24. name: istio-galley
  25. namespace: istio-system
  26. path: /admitpilot
  27. failurePolicy: Fail
  28. name: pilot.validation.istio.io
  29. namespaceSelector: {}
  30. rules:
  31. - apiGroups:
  32. - config.istio.io
  33. apiVersions:
  34. - v1alpha2
  35. operations:
  36. - CREATE
  37. - UPDATE
  38. resources:
  39. - httpapispecs
  40. - httpapispecbindings
  41. - quotaspecs
  42. - quotaspecbindings
  43. - apiGroups:
  44. - rbac.istio.io
  45. apiVersions:
  46. - '*'
  47. operations:
  48. - CREATE
  49. - UPDATE
  50. resources:
  51. - '*'
  52. - apiGroups:
  53. - authentication.istio.io
  54. apiVersions:
  55. - '*'
  56. operations:
  57. - CREATE
  58. - UPDATE
  59. resources:
  60. - '*'
  61. - apiGroups:
  62. - networking.istio.io
  63. apiVersions:
  64. - '*'
  65. operations:
  66. - CREATE
  67. - UPDATE
  68. resources:
  69. - destinationrules
  70. - envoyfilters
  71. - gateways
  72. - virtualservices
  73. - clientConfig:
  74. # caBundle should be non-empty. This is periodically (re)patched
  75. # every second by the webhook service using the ca-cert
  76. # from the mounted service account secret.
  77. caBundle: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUM1VENDQWMyZ0F3SUJBZ0lRVzVYNWpJcnJCemJmZFdLaWVoaVVSakFOQmdrcWhraUc5dzBCQVFzRkFEQWMKTVJvd0dBWURWUVFLRXhGck9ITXVZMngxYzNSbGNpNXNiMk5oYkRBZUZ3MHhPREEzTWpjeE56VTJNakJhRncweApPVEEzTWpjeE56VTJNakJhTUJ3eEdqQVlCZ05WQkFvVEVXczRjeTVqYkhWemRHVnlMbXh2WTJGc01JSUJJakFOCkJna3Foa2lHOXcwQkFRRUZBQU9DQVE4QU1JSUJDZ0tDQVFFQXdVMi9SdWlyeTNnUzdPd2xJRCtaaGZiOEpOWnMKK05OL0dRWUsxbVozb3duaEw4dnJHdDBhenpjNXFuOXo2ZEw5Z1pPVFJXeFVCYXVJMUpOa3d0dSt2NmRjRzlkWgp0Q2JaQWloc1BLQWQ4MVRaa3RwYkNnOFdrcTRyNTh3QldRemNxMldsaFlPWHNlWGtRejdCbStOSUoyT0NRbmJwCjZYMmJ4Slc2OGdaZkg2UHlNR0libXJxaDgvZ2hISjFha3ptNGgzc0VGU1dTQ1Y2anZTZHVJL29NM2pBem5uZlUKU3JKY3VpQnBKZmJSMm1nQm4xVmFzNUJNdFpaaTBubDYxUzhyZ1ZiaHp4bWhpeFhlWU0zQzNHT3FlRUthY0N3WQo0TVczdEJFZ3NoN2ovZGM5cEt1ZG1wdFBFdit2Y2JnWjdreEhhazlOdFV2YmRGempJeTMxUS9Qd1NRSURBUUFCCm95TXdJVEFPQmdOVkhROEJBZjhFQkFNQ0FnUXdEd1lEVlIwVEFRSC9CQVV3QXdFQi96QU5CZ2txaGtpRzl3MEIKQVFzRkFBT0NBUUVBTnRLSnVkQ3NtbTFzU3dlS2xKTzBIY1ZMQUFhbFk4ZERUYWVLNksyakIwRnl0MkM3ZUtGSAoya3JaOWlkbWp5Yk8xS0djMVlWQndNeWlUMGhjYWFlaTdad2g0aERRWjVRN0k3ZFFuTVMzc2taR3ByaW5idU1aCmg3Tm1WUkVnV1ZIcm9OcGZEN3pBNEVqWk9FZzkwR0J6YXUzdHNmanI4RDQ1VVRJZUw3M3hwaUxmMXhRTk10RWEKd0NSelplQ3lmSUhra2ZrTCtISVVGK0lWV1g2VWp2WTRpRDdRR0JCenpHZTluNS9KM1g5OU1Gb1F3bExjNHMrTQpnLzNQdnZCYjBwaTU5MWxveXluU3lkWDVqUG5ibDhkNEFJaGZ6OU8rUTE5UGVULy9ydXFRNENOancrZmVIbTBSCjJzYmowZDd0SjkyTzgwT2NMVDlpb05NQlFLQlk3cGlOUkE9PQotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0tCg==
  78. service:
  79. # service corresponds to the Kubernetes service that implements the
  80. # webhook, e.g. istio-galley.istio-system.svc:443
  81. name: istio-galley
  82. namespace: istio-system
  83. path: /admitmixer
  84. failurePolicy: Fail
  85. name: mixer.validation.istio.io
  86. namespaceSelector: {}
  87. rules:
  88. - apiGroups:
  89. - config.istio.io
  90. apiVersions:
  91. - v1alpha2
  92. operations:
  93. - CREATE
  94. - UPDATE
  95. resources:
  96. - rules
  97. - attributemanifests
  98. - circonuses
  99. - deniers
  100. - fluentds
  101. - kubernetesenvs
  102. - listcheckers
  103. - memquotas
  104. - noops
  105. - opas
  106. - prometheuses
  107. - rbacs
  108. - servicecontrols
  109. - solarwindses
  110. - stackdrivers
  111. - statsds
  112. - stdios
  113. - apikeys
  114. - authorizations
  115. - checknothings
  116. - listentries
  117. - logentries
  118. - metrics
  119. - quotas
  120. - reportnothings
  121. - servicecontrolreports
  122. - tracespans

If the validatingwebhookconfiguration doesn’t exist, verify theistio-galley-configuration configmap exists. istio-galley usesthe data from this configmap to create and update thevalidatingwebhookconfiguration.

  1. $ kubectl -n istio-system get configmap istio-galley-configuration -o jsonpath='{.data}'
  2. map[validatingwebhookconfiguration.yaml:apiVersion: admissionregistration.k8s.io/v1beta1
  3. kind: ValidatingWebhookConfiguration
  4. metadata:
  5. name: istio-galley
  6. namespace: istio-system
  7. labels:
  8. app: istio-galley
  9. chart: galley-1.0.0
  10. release: istio
  11. heritage: Tiller
  12. webhooks:
  13. - name: pilot.validation.istio.io
  14. clientConfig:
  15. service:
  16. name: istio-galley
  17. namespace: istio-system
  18. path: "/admitpilot"
  19. caBundle: ""
  20. rules:
  21. - operations:
  22. (... snip ...)

If the webhook array in istio-galley-configuration is empty, verifythe galley.enabled and global.configValidation installation options areset.

The istio-galley validation configuration is fail-close. Ifconfiguration exists and is scoped properly, the webhook will beinvoked. A missing caBundle, bad certificate, or network connectivityproblem will produce an error message when the resource iscreated/updated. If you don’t see any error message and the webhookwasn’t invoked and the webhook configuration is valid, your cluster ismisconfigured.

Creating configuration fails with x509 certificate errors

x509: certificate signed by unknown authority related errors aretypically caused by an empty caBundle in the webhookconfiguration. Verify that it is not empty (see verify webhookconfiguration). Theistio-galley deployment consciously reconciles webhook configurationused the istio-galley-configuration configmap and root certificatemounted from istio.istio-galley-service-account secret in theistio-system namespace.

  • Verify the istio-galley pod(s) are running:
  1. $ kubectl -n istio-system get pod -listio=galley
  2. NAME READY STATUS RESTARTS AGE
  3. istio-galley-5dbbbdb746-d676g 1/1 Running 0 2d
  • Verify you’re using Istio version >= 1.0.0. Older version of Galleydid not properly re-patch the caBundle. This typically happenedwhen the istio.yaml was re-applied, overwriting a previouslypatched caBundle.
  1. $ for pod in $(kubectl -n istio-system get pod -listio=galley -o jsonpath='{.items[*].metadata.name}'); do \
  2. kubectl -n istio-system exec ${pod} -it /usr/local/bin/galley version| grep ^Version; \
  3. done
  4. Version: 1.0.0
  • Check the Galley pod logs for errors. Failing to patch thecaBundle should print an error.
  1. $ for pod in $(kubectl -n istio-system get pod -listio=galley -o jsonpath='{.items[*].metadata.name}'); do \
  2. kubectl -n istio-system logs ${pod} \
  3. done
  • If the patching failed, verify the RBAC configuration for Galley:
  1. $ kubectl get clusterrole istio-galley-istio-system -o yaml
  2. apiVersion: rbac.authorization.k8s.io/v1
  3. kind: ClusterRole
  4. metadata:
  5. labels:
  6. app: istio-galley
  7. name: istio-galley-istio-system
  8. rules:
  9. - apiGroups:
  10. - admissionregistration.k8s.io
  11. resources:
  12. - validatingwebhookconfigurations
  13. verbs:
  14. - '*'
  15. - apiGroups:
  16. - config.istio.io
  17. resources:
  18. - '*'
  19. verbs:
  20. - get
  21. - list
  22. - watch
  23. - apiGroups:
  24. - '*'
  25. resourceNames:
  26. - istio-galley
  27. resources:
  28. - deployments
  29. verbs:
  30. - get

istio-galley needs validatingwebhookconfigurations write access tocreate and update the istio-galley validatingwebhookconfiguration.

Creating configuration fails with no such hosts or no endpoints available errors

Validation is fail-close. If the istio-galley pod is not ready,configuration cannot be created and updated. In such cases you’ll seean error about no endpoints available.

Verify the istio-galley pod(s) are running and endpoints are ready.

  1. $ kubectl -n istio-system get pod -listio=galley
  2. NAME READY STATUS RESTARTS AGE
  3. istio-galley-5dbbbdb746-d676g 1/1 Running 0 2d
  1. $ kubectl -n istio-system get endpoints istio-galley
  2. NAME ENDPOINTS AGE
  3. istio-galley 10.48.6.108:15014,10.48.6.108:443 3d

If the pods or endpoints aren’t ready, check the pod logs andstatus for any indication about why the webhook pod is failing to startand serve traffic.

  1. $ for pod in $(kubectl -n istio-system get pod -listio=galley -o jsonpath='{.items[*].metadata.name}'); do \
  2. kubectl -n istio-system logs ${pod} \
  3. done
  1. $ for pod in $(kubectl -n istio-system get pod -listio=galley -o name); do \
  2. kubectl -n istio-system describe ${pod} \
  3. done