By defining a Landing Zone for OpenShift certain configurations can be enforced during replication.
With OpenShift ResourceQuotas the number of resources inside a namespace (meshProject) can be limited. In order to setup such a quota limit write, or drag and drop, your OpenShift ResourceQuota file into the respective field when creating a Landing Zone.
Templates can also be synchronized automatically with OpenShift if they are put into a Landing Zone and assigned to a meshProject. This is similar to the ResourceQuotas handling. This template then shows up in the web console and can be applied manually by the user. Currently only one template can be uploaded and managed this way.
It is possible to automatically instance this template inside a project via meshStacks project replication procedure. However doing so requires currently that the service principal, created with the rights above, gets all the additional rights required to instance the template. Like for example creating Pods. This might be not desirable and because of this this function is disabled by default. To enable automatic Template instancing set the flag
enableTemplateInstancing to true:
replicator-openshift: platforms: - platform: okd.eu-de-central enableTemplateInstancing: true
Labels are used to identify existing Resources inside OpenShift or Kubernetes projects. It is possible to define a set of default labels which get applied to every resource created via meshStack. Usually these managed resources are created by a Landing Zone configuration (e.g. ResourceQuotas or Templates).
In order to set these default labels use the replicator OpenShift platform configuration and set the property
default-resource-labels like so:
replicator-openshift: platforms: - platform: okd.eu-de-central default-resource-labels: my-label-1: sample-value-123 my-label-2: sample-value-456
You can also specify certain labels which are populated via data from the meshProject spec. This can be for example a costcenter id. You need to map these fields via the replicator config as well:
replicator-openshift: platforms: - platform: okd.eu-de-central meta-label-mappings: costCenter: io.meshcloud/costCenter
This configuration will map the value from the specs metadata with the key
costCenter to an OpenShift label with the key
io.meshcloud/costCenter. The datapoints available in the specs for mapping might be differnt depending on the configured environment of your meshStack installation. Please contact the support for more details.