Configure Lock Schema for Manifests
Last updated
Last updated
In Devtron, you can create CRDs for defining lock schema. Your lock schema will be used to determine the fields (in the resource manifest) that cannot be added/updated/deleted by non-superadmins. This is especially useful for preventing unwanted edits to the manifests of pod, deployment, configmap, and many more.
Go to Resource Browser and select your cluster.
Use the searchbox labelled 'Jump to Kind' and search for LockSchema
.
Click the Lock Schema you wish to edit. In case no Lock Schema exists, you may create a Lock Schema for your resource kind.
Click Edit Live Manifest to modify the YAML.
Locate the lockedPaths
list and specify the fields/paths you wish to lock from unwanted edits by non-superadmins in the manifest.
Click Apply Changes.
Go to Resource Browser and select your cluster.
Click Create Resource at the top.
Use the following template and specify the fields/paths you wish to lock in the lockedPaths
list, also specify the resource kinds in applyTo
. Once done, click Apply.