Config#
Configs are partial or complete pieces of configuration that are intended to be deployed to the referenced target.
Attributes#
config
: Is a list of configuration pieces that consist of apath
and avalue
attribute.path
: The path describes where the configuration (value
) part is rooted. This can either by/
to indicate the configuration root level or any valid path within the schema.value
: The canfiguration in yaml format that is meant to go under thepath
in the target device.
priority
: The priority field is used as a tie-breaker, when multiple Config intents try to set overlapping configurationslifecycle
: Lifecycle determines the lifecycle policies of the resource e.g. delete orphan or deletedeletionPolicy
: DeletionPolicy defines the deletion policy of the resource.delete
: (default) deletes the config from the targetorphan
: does NOT delete the config from the target
Example#
apiVersion: config.sdcio.dev/v1alpha1
kind: Config
metadata:
name: test
namespace: default
labels:
config.sdcio.dev/targetName: dev1
config.sdcio.dev/targetNamespace: default
spec:
priority: 10
config:
- path: /
value:
interface:
- name: "system0"
admin-state: "enable"
description: "k8s-system0-dummy"
Example with deletion policy orphan#
apiVersion: config.sdcio.dev/v1alpha1
kind: Config
metadata:
name: test-orphan
namespace: default
labels:
config.sdcio.dev/targetName: dev1
config.sdcio.dev/targetNamespace: default
spec:
lifecycle:
deletionPolicy: orphan
priority: 10
config:
- path: /
value:
interface:
- name: "system0"
admin-state: "enable"
description: "k8s-system0-dummy"