Description
Our custom resources repository, component, resource, and deployer can specify an OCMConfig that refers to a Secret, ConfigMap, or one of our afore-mentioned custom resources. This information is propagated by default. However, a user needs to specify a propagated OCMConfig by specifying the custom resource.
For example:
# Custom resource specifying an OCM configuration through a Secret (propagated by default)
apiVersion: delivery.ocm.software/v1alpha1
kind: Repository
metadata:
name: basic-auth-repository
spec:
...
ocmConfig:
- kind: Secret
name: basic-auth
# Custom resource specifying an OCM configuration through the custom resource repository
apiVersion: delivery.ocm.software/v1alpha1
kind: Component
metadata:
name: basic-auth-component
spec:
RepositoryRef: basic-auth-repository
...
ocmConfig:
- kind: Repository
apiVersion: delivery.ocm.software/v1alpha1
name: basic-auth
We want to increase the UX by removing the explicit reference to the propagated OCMConfig as the reference is already set through the RepositoryRef. Hence, users can expect that a custom resource referencing another custom resource will automatically check for OCMConfigs (in their Status field EffectiveOCMConfig) as long as the custom resource does not specify any additional OCMConfig.
This would do the same as the above example:
# Custom resource specifying an OCM configuration through a Secret (propagated by default)
apiVersion: delivery.ocm.software/v1alpha1
kind: Repository
metadata:
name: basic-auth-repository
spec:
...
ocmConfig:
- kind: Secret
name: basic-auth
# Custom resource specifying an OCM configuration through the custom resource repository
apiVersion: delivery.ocm.software/v1alpha1
kind: Component
metadata:
name: basic-auth-component
spec:
RepositoryRef: basic-auth-repository
...
As this changes the default behaviour of our custom resources, the change is considered a breaking API change.
Done Criteria
Description
Our custom resources
repository,component,resource, anddeployercan specify anOCMConfigthat refers to aSecret,ConfigMap, or one of our afore-mentioned custom resources. This information is propagated by default. However, a user needs to specify a propagatedOCMConfigby specifying the custom resource.For example:
We want to increase the UX by removing the explicit reference to the propagated
OCMConfigas the reference is already set through theRepositoryRef. Hence, users can expect that a custom resource referencing another custom resource will automatically check forOCMConfigs (in their Status fieldEffectiveOCMConfig) as long as the custom resource does not specify any additionalOCMConfig.This would do the same as the above example:
As this changes the default behaviour of our custom resources, the change is considered a breaking API change.
Done Criteria
GetEffectiveConfig()with the above-mentioned functionalityOCMConfigis specified in aComponent,Resource, orDeployer, it should check forOCMConfigs in the referenced resource and use thatComponent,Resource, andDeployer