Append content to a file using MachineConfig is not working in Openshift 4

Solution Verified - Updated -

Issue

  • How can I append content to a file using machine-config-operator?
  • Trying to append content to a file inside RHCOS using MachineConfig, MachineConfigPool throws the error:

    $ oc get mcp worker -o jsonpath='{.status.conditions[?(@.type=="RenderDegraded")].message}'
    Failed to render configuration for pool worker: parsing Ignition config spec v3.1 failed with error: config is not valid
    Report: error at line 1 col 67: json: cannot unmarshal bool into Go struct field File.storage.files.append of type []types.Resource
    

Environment

  • Red Hat OpenShift Container Platform (OCP) 4.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content