UI and GitOps
UI Editing and GitOps are mutually exclusive. We recommend starting off using the UI editor, which includes a built-in YAML editor, and switching over to GitOps when ready for a wider rollout.
If you have previously used GitOps and temporarily turn on UI editing, these changes will be temporary and will not correlate from Cortex back into GitHub. The next time the file is changed in Git, it will override the changes made in the UI.
GitOps and API
The last received change in a
cortex.yaml, whether from the Create or Update Entity API or a push from Git via GitOps, overrides previous changes.
For instance, if you add a new field to
cortex.yaml with the Create or Update Entity API, this will be reflected in Cortex. Then, if you make a change to
cortex.yaml using GitOps, that entire file in Git will be reflected in Cortex. Changes are not appended, but the last submitted entire file take precedence (changes are not appended, and would remove any fields that are omitted in the
cortex.yaml), whether that is from the Create or Update Entity API or GitOps.