Azure-docs: yaml file is invalid

Created on 12 Dec 2018  Â·  7Comments  Â·  Source: MicrosoftDocs/azure-docs

When you do a copy of the yaml file in this document, there are a lot of wrong indentations/whitespaces and you'll get errors like:
error: error converting YAML to JSON: yaml: line 8: did not find expected key


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Azure-Monitosvc assigned-to-author doc-bug triaged

All 7 comments

@mrdfuse Thanks for bringing this to our attention. Your feedback has been shared with the content owner for further review.

Looks like an extra 'space' before 'roleRef'

Use this instead until the docs are fixed:

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
   name: containerHealth-log-reader
rules:
   - apiGroups: [""]
     resources: ["pods/log"]
     verbs: ["get"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
   name: containerHealth-read-logs-global
roleRef:
  kind: ClusterRole
  name: containerHealth-log-reader
  apiGroup: rbac.authorization.k8s.io
subjects:
   - kind: User
     name: clusterUser
     apiGroup: rbac.authorization.k8s.io

Oh yeah, it's not that I wanted a corrected version, I have done that myself :) I just wanted to point this out because other people will surely have the same problem when copy pasting.

@mrdfuse & @femsulu - I've just returned from holiday and catching up on things. I'll bug this and see about getting it corrected as soon as possible. Thank you for bringing this to our attention and my apologies for the problems it caused.

please-close as I updated the article and the new version of the article should be released today. Thanks!

@mrdfuse Thanks for bringing this to our attention. We will now close this issue. If there are further questions regarding this matter, please tag me in a comment. I will reopen it and we will gladly continue the discussion.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bdcoder2 picture bdcoder2  Â·  3Comments

behnam89 picture behnam89  Â·  3Comments

bityob picture bityob  Â·  3Comments

mrdfuse picture mrdfuse  Â·  3Comments

spottedmahn picture spottedmahn  Â·  3Comments