-
Notifications
You must be signed in to change notification settings - Fork 15.4k
Patch PowerShell example does not work on Windows #17630
Copy link
Copy link
Closed
Labels
good first issueDenotes an issue ready for a new contributor, according to the "help wanted" guidelines.Denotes an issue ready for a new contributor, according to the "help wanted" guidelines.help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.priority/backlogHigher priority than priority/awaiting-more-evidence.Higher priority than priority/awaiting-more-evidence.sig/windowsCategorizes an issue or PR as relevant to SIG Windows.Categorizes an issue or PR as relevant to SIG Windows.
Description
This is a Bug Report
kubectl PowerShell example does not work in Windows. cat is an alias for Get-Content, which by default parses a file line-by-line.
Proposed Solution:
Change PowerShell example to use the -Raw flag in Get-Content cmdlet (and change cat to Get-Content to avoid ambiguity between the Windows Get-Command alias and Unix cat command).
kubectl patch deployment patch-demo --patch $(Get-Content patch-file.yaml -Raw)
Page to Update:
https://kubernetes.io/docs/tasks/run-application/update-api-object-kubectl-patch/
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
good first issueDenotes an issue ready for a new contributor, according to the "help wanted" guidelines.Denotes an issue ready for a new contributor, according to the "help wanted" guidelines.help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.priority/backlogHigher priority than priority/awaiting-more-evidence.Higher priority than priority/awaiting-more-evidence.sig/windowsCategorizes an issue or PR as relevant to SIG Windows.Categorizes an issue or PR as relevant to SIG Windows.