
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 956 Views
The first step of the last lab is the command:
oc patch installplan install-4k2q8 --type merge --patch '{"spec":{"approved":true}}'
This did not seem to work.
So I used install-dpsnp and it worked fine!
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 943 Views
Hi MarkosS,
if you used the patch command from the solution literally with install-4k2q8, it won't work. You have to get your own install plan with:
oc get installplan
It will differ from install-4k2q8, e.g. for me it was: install-dnsnr
Of course you can combine oc get installplan and oc patch in a way like:
oc patch installplan $(oc get installplans.operators.coreos.com | awk '{ print $1 }') --type merge --patch '{"spec":{"approved":true}}'
$(oc get installplans.operators.coreos.com | sed 1d | awk '{ print $1 }') drops the header line of the output (NAME CSV APPROVAL APPROVED) and awk '{ print $1 }' gives you the first column, which is your installplan.
This command of course will only work with one install plan.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 944 Views
Hi MarkosS,
if you used the patch command from the solution literally with install-4k2q8, it won't work. You have to get your own install plan with:
oc get installplan
It will differ from install-4k2q8, e.g. for me it was: install-dnsnr
Of course you can combine oc get installplan and oc patch in a way like:
oc patch installplan $(oc get installplans.operators.coreos.com | awk '{ print $1 }') --type merge --patch '{"spec":{"approved":true}}'
$(oc get installplans.operators.coreos.com | sed 1d | awk '{ print $1 }') drops the header line of the output (NAME CSV APPROVAL APPROVED) and awk '{ print $1 }' gives you the first column, which is your installplan.
This command of course will only work with one install plan.