-
Notifications
You must be signed in to change notification settings - Fork 553
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
YAML output of machine config incorrectly formatted for multidoc configurations #8687
Closed
Tracked by
#8484
Comments
Yes, this is true. We don't have an easy answer for it, so we need to figure out what to do for it, as it won't an easy answer. |
A workaround for now is to do |
Decision: Change |
Can we drop the |
DmitriyMV
added a commit
to DmitriyMV/talos
that referenced
this issue
Jul 5, 2024
For `get mc -o json|yaml` we pretend that `spec` field is string and not an actual yaml map. That way you can see the full spec in unformatted view using `talosctl -n <node> get mc -o yaml` or formatted using `talosctl -n <node> get mc -o yaml | yq .spec`. `edit mc` command is unaffected. Fixes siderolabs#8687 Signed-off-by: Dmitriy Matrenichev <dmitry.matrenichev@siderolabs.com>
DmitriyMV
added a commit
to DmitriyMV/talos
that referenced
this issue
Jul 8, 2024
For `get mc -o json|yaml` we pretend that `spec` field is string and not an actual yaml map. That way you can see the full spec in unformatted view using `talosctl -n <node> get mc -o yaml` or formatted using `talosctl -n <node> get mc -o yaml | yq .spec`. `edit mc` command is unaffected. Fixes siderolabs#8687 Signed-off-by: Dmitriy Matrenichev <dmitry.matrenichev@siderolabs.com>
DmitriyMV
added a commit
to DmitriyMV/talos
that referenced
this issue
Jul 8, 2024
For `get mc -o json|yaml` we pretend that `spec` field is string and not an actual yaml map. That way you can see the full spec in unformatted view using `talosctl -n <node> get mc -o yaml` or formatted using `talosctl -n <node> get mc -o yaml | yq .spec`. `edit mc` command is unaffected. Fixes siderolabs#8687 Signed-off-by: Dmitriy Matrenichev <dmitry.matrenichev@siderolabs.com>
DmitriyMV
added a commit
to DmitriyMV/talos
that referenced
this issue
Jul 8, 2024
For `get mc -o json|yaml` we pretend that `spec` field is string and not an actual yaml map. That way you can see the full spec in unformatted view using `talosctl -n <node> get mc -o yaml` or formatted using `talosctl -n <node> get mc -o yaml | yq .spec`. `edit mc` command is unaffected. Fixes siderolabs#8687 Signed-off-by: Dmitriy Matrenichev <dmitry.matrenichev@siderolabs.com>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Bug Report
Multidoc YAML configurations after the first document are incorrectly indented 4 spaces
Description
if you edit the machine config and append a new document for the ingress firewall rules, it displays correctly with
talosctl edit mc
, but the output oftalosctl get mc
will show the documents after the first YAML doc incorrectly indented, which breaks processing withyq
.The multi-docs are applied correctly by Talos - it is just in display they are mal-formatted.
Logs
e.g. append a YAML document End via editing the machine config thus:
and it will show thus via
get mc -o yaml
Environment
kubectl version --short
]talosctl
and alsoomnictl get redactedclustermachineconfig
The text was updated successfully, but these errors were encountered: