cancel
Showing results for 
Search instead for 
Did you mean: 
Rajbatra
Mission Specialist
Mission Specialist
  • 13.1K Views

LAB 280 - Unable to save file through OC edit command

Jump to solution

Hi,

I am doing Lab, there i am trying to save file through OC edit command, but it is showing error.

student@workstation ~]$ oc edit deployment/hello
A copy of your changes has been stored to "/tmp/oc-edit-1fi7k.yaml"
error: Edit cancelled, no valid changes were saved.

Let us know , how to save file through oc edit command?

Thanks

Rajkumar Batra

Labels (1)
23 Replies
flozano
Moderator
Moderator
  • 2,760 Views

All Kubernetes resources store labels as part of their metadata. You can use "oc get kind name -o yaml" to see a complete, raw resource definition and "oc get kind name --show-labels" to see just labels

The app label used to be standard in apps created by oc new-app but with recent releases of OpenShift it might not be created for all scenarios. Developers are free to add as many labels they wish for their resources and it is common practice to add a common label to all resources related to an application or service to make it easier to track them.

Brati
Cadet
Cadet
  • 1,645 Views

Had the same issue with oc edit oauth. Finally it turns out that I was missing a space after spec: . The format should be spec: {}.

This is for the first Guided Exercise of Ch 3 for DO280 for 4.6 version.

Oliver2
Mission Specialist
Mission Specialist
  • 1,122 Views

Hello, was this problem ever rectified? I'm having the same exact issue for the same lab excercise while studying for EX288.

Chetan_Tiwary_
Community Manager
Community Manager
  • 1,113 Views

@Oliver2 Based on the previous comment - learner was able to save it after rectifying a minor error. 

If you still need help, I suggest to raise a support ticket - our team will check this and help you with an update. 

0 Kudos
Join the discussion
You must log in to join this conversation.