serverProperties parameter
- Each property can define its property list and associate it with a group name. Servers can refer these properties by using the group name. Each property can define child or derived properties, which can inherit and override its parent properties.
serverProperties:serverProperties:
envVars:
- groupName: ""
propertyList: {}
propertyRef:
- name: ""
valueFrom:
configMapKeyRef:
key: ""
name: ""
optional:
- name: ""
secretKeyRef:
key: ""
name: ""
optional:
- name: ""
fieldRef:
apiVersion: ""
fieldPath: ""
- name: ""
resourceFieldRef:
containerName: ""
divisor: "1"
resource: ""
propertyFrom:
- prefix: ""
configMapRef:
name: ""
optional: ""
- prefix: ""
secretRef:
name: ""
optional: ""
derivatives: []
jvmArgs:
- groupName: ""
propertyList:
- ""
derivatives: []envVars
properties of serverProperties parameter:
| Property | Default value | Value type | Required | Description |
|---|---|---|---|---|
envVars.groupName |
string | Yes | Specify the name of the property group. You can use the following group names to specify the
environment variables.
|
|
envVars.propertyList |
object | No | For envVars, specify the properties as key-value pair. | |
envVars.propertyRef |
object | No | Specify a list of property names with their corresponding source as either as a configMap or as a secret. For more information, see propertyRef parameter. | |
envVars.propertyFrom |
object | No | Specify a list of envFromSource with the corresponding configmap and secret name. | |
envVars.derivatives |
array | No | Specify a list of derived properties that includes groupName, propertyList, and extra list of derived properties, if any. |
jvmArgs properties of
serverProperties parameter:
| Property | Default value | Value type | Required | Description |
|---|---|---|---|---|
jvmArgs.groupName |
string | Yes | Specify the name of the property group. You can use the following group names to specify the
JVM arguments for servers.
|
|
jvmArgs.propertyList |
array | Yes | For jvmArgs, specify properties as an array list. | |
jvmArgs.derivatives |
array | No | Specify a list of derived properties that includes groupName and propertyList. |
propertyFrom parameter
The following table explains the attributes applicable for the propertyFrom
parameter.
| Property | Default value | Value type | Required | Description |
|---|---|---|---|---|
PropertyFrom.prefix |
string | No | Specify the name of the prefix that should be appended to the property name that is read from configMaps and secrets. Define this prefix when you want the deployment to read similar set of properties. | |
PropertyFrom.configMapRef |
object | Yes | Specify the name of the configMap from which the properties are read. | |
PropertyFrom.SecretRef |
object | Yes | Specify the name of the secret from which the properties are read. |
propertyRef parameter
The following table explains the attributes applicable for the propertyRef
parameter. propertyRef is an array containing one or more occurrences of
name and valueFrom fields. The valueFrom field
supports configMapKeyRef, secretKeyRef, fieldRef,
and resourceFieldRef.
| Property | Default value | Value type | Required | Description |
|---|---|---|---|---|
propertyRef.name |
string | Yes | Specify the name of the property to be exposed as
or envVars. |
|
|
object | Yes |
The |
Servers properties for envVars
The following examples show three ways to define servers properties including envVars in SIPEnvironment custom resource.
- Define the properties directly from
propertyListin key-value pairs.Example:
spec: serverProperties: envVars: - groupName: iv_properties propertyList: ivproperty1: value1 ivproperty2: value2 - Define the properties directly from the whole of configMaps and secrets. For more information
about
propertyFromproperties, see propertyFrom parameter.Example:
spec: serverProperties: envVars: - groupName: iv_properties propertyFrom: - prefix: name_of_prefix configMapRef: name: name_config_map optional: true - prefix: name_of_prefix secretRef: name: name_of_secret optional: true - Define the properties by one or more properties from configMaps and secrets. For more
information about
propertyRefproperties, see propertyRef parameter.Example:
spec: serverProperties: envVars: - groupName: iv_properties propertyRef: - name: ivproperty1 valueFrom: configMapKeyRef: key: key_ivproperty1 name: name_of_configmap optional: true - name: ivproperty2 valueFrom: secretKeyRef: key: key_ivproperty2 name: name_of_the_secret optional: true
Servers properties for jvmArgs
jvmArgsspec:
serverProperties:
jvmArgs:
- groupName: iv_jvmargs
propertyList:
- "-Xms512m"
- "-Xmx2048m"
- '-Djavax.net.debug=all'After the envVars and jvmArgs are defined in servers properties in any one of the given ways, you can refer these envVars and jvmArgs in any of the service group definitions. For example, in IVServiceGroup, you can use the name of these groups, so that servers can refer these properties by using the group name.
apiVersion: apps.sip.ibm.com/v1beta1
kind: IVServiceGroup
metadata:
name: dev
namespace: <sip_installation_namespace>
spec:
active: true
property:
envVars: iv_properties
jvmArgs: iv_jvmargs