Helm values
When you create a project with DX Cloud, a values.yml file is generated for you from the PaaS Helm Chart.
The values.yml file contains important project information for configuring items such as:
Can I change the configuration values in the values.yml file?
Yes, you can change the values for certain properties in the values.yml file.
However, it’s important that you don’t change some values as this could have serious consequences for your project.
This page guides you through the properties that you can change while helping you avoid changing the wrong properties.
Update Helm chart version
You update the Helm chart version in the .gitlab-ci.yaml file.
You must modify the version, the values file, and the namespace.
Pipeline configuration may vary by customer implementation; though we do provide blueprints.
Ensure you adapt the configuration accordingly to fit the project requirements.
Global variable
Specify the desired Helm chart version here. This shows the latest version.
.gitlab.ci.yaml file
variables:
HELM_CHART_VERSION: 1.23.0
Command line
...
helm upgrade prod mironet magnolia-helm --version 1.23.0 -f values_new.yml -n prod
...
Ingresses
An Ingress resource defines rules for how external HTTP/HTTPS traffic should be routed to services within a cluster.
The ingress: section in the values.yml file contains configurable properties around enabling the ingress, annotations, hosts, and transport layer security.
The properties shown in the example below are configurable.
ingress:
enabled: true <1>
annotations:
kubernetes.io/ingress.class: "nginx"
nginx.ingress.kubernetes.io/proxy-body-size: 512m
cert-manager.io/cluster-issuer: "letsencrypt-prod" <2>
hosts:
- host: {{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io
paths:
- path: /
instance: author
port: https
- host: {{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io
paths:
- path: /
instance: public
port: https
tls:
- hosts:
- {{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io
- {{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io
## - {{ .Env.DEPLOYMENT }}.frontend-author.paastraining.magnolia-platform.io
## - {{ .Env.DEPLOYMENT }}.frontend-public.paastraining.magnolia-platform.io
secretName: {{ .Env.DEPLOYMENT }}-paastraining-magnolia-platform-io
...
enabled must be true for the ingress configuration to work.
true is the default value when creating a DX Cloud project.
Exclude this annotation if using a custom certificate.
Ingress properties
| Property | Description |
|---|---|
enabled | Enable or disable the ingress file. |
annotations | While a basic Ingress allows you to define hostnames, paths, and rules, annotations extend its functionality with more advanced configurations. Usually, annotations are used to enhance security, manage traffic, and handle custom behaviors. This is the section where you add any necessary annotations for your project. See Annotations for more details on different annotation options. > Tip: If in doubt, check with DX Cloud support before adding any additional annotations. |
hosts | Specify hosts. This includes setting the service port if necessary. See the hosts example below. |
tls | Specify hosts using transport layer security. Specify a secret name here if you already have a certificate stored and know its name. If this is not specified, lets-encrypt is used to issue a new certificate. See the TLS example below. |
hosts example
- host: {{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io
paths:
- path: /
instance: author
port: https <1>
If SSO is failing due to incorrect protocol inference, setting the port to https in the Helm chart ensures Magnolia will generate redirect URLs using HTTPS.
To do this, ideally, you should be using Helm 1.23.0 or 1.22.0.
TLS example
tls:
- hosts:
- {{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io
- {{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io
secretName: {{ .Env.DEPLOYMENT }}-paastraining-magnolia-platform-io <1>
Specify the secretName.
Annotations
This section provides you with some annotation examples that you can use in your DX Cloud project.
Whitelisting IPs
If you need to whitelist a range of IPs, this can be set using an ingress annotation. The annotation specifies a list of allowed IP ranges in CIDR format, separated by commas.
If you have a CDN, the CDN IPs must be entered in the whitelist range. If you have an internal service, the service’s IPs must be entered in the whitelist range.
nginx.ingress.kubernetes.io/whitelist-source-range: "192.168.1.1/32, 10.0.0.0/16"
Request body buffer
You might want to control the buffer size that NGINX uses to store the request body before passing it on to the backend service. This is useful when dealing with larger payloads, such as file uploads.
nginx.ingress.kubernetes.io/client-body-buffer-size: "16k" <1>
NGINX uses a buffer size of 16k or 8k depending on the platform (16k for 64-bit systems, 8k for 32-bit systems).
You can also define the size using k for kilobytes, m for megabytes, or bytes with no suffix required.
Package Manager
If you’re using our Package Manager, you need to configure your ingress to handle large package uploads and extended processing times. Package Manager allows you to upload, install, and manage packages that can be several hundred megabytes in size, and these operations may take several minutes to complete.
ingress:
annotations:
nginx.ingress.kubernetes.io/proxy-body-size: 512m <1>
nginx.ingress.kubernetes.io/proxy-read-timeout: 300 <2>
nginx.ingress.kubernetes.io/proxy-send-timeout: 300 <3>
Maximum size of the HTTP request body. Package Manager handles large binary package uploads that can exceed the default nginx limit. Consider setting this to at least 512m, or higher depending on your expected package sizes.
Maximum time (in seconds) nginx waits to read data from the Magnolia backend. Package installation and processing operations can take several minutes. Consider setting this to at least 300 seconds (5 minutes) for long-running package operations.
Maximum time (in seconds) nginx waits to send data to the Magnolia backend. Large package uploads require extended transmission time. Consider setting this to at least 300 seconds (5 minutes) for complete package uploads.
Images
The image: section of your values.yml file decides which image to use, how to pull the image, and whether authentication is needed, as it would be in the case for private registries.
The properties shown in the example below are configurable.
image:
tomcat:
tag: "10.1-jre17-temurin" <1>
pullSecrets: <2>
- name: gitlab
pullPolicy: Always <3>
The tag of the image to use.
For Magnolia 6.4 and later, you should use 10.1-jre17-temurin.
For Magnolia 6.3 and earlier, you should use 9.0-jre17-temurin.
Provides credentials for pulling images from private registries.
In this case, gitlab is used to pull from the private GitLab container registry.
Defines when to pull the image.
Options are Always, IfNotPresent, Never.
Magnolia Author
The magnoliaAuthor section of your values.yml file handles important configuration for the Magnolia Author instance.
The author instance is where authors, also sometimes referred to as editors, are able to create and edit pages, and publish content.
The properties shown in the example below are configurable.
magnoliaAuthor:
enabled: true
restartPolicy: Always
redeploy: true
bootstrap:
password: superuser!
activation:
useExistingSecret: False
contextPath: /
base_url: https://{{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io/
sameSiteCookies: strict
env:
- name: instance
value: "author"
- name: deployment
value: {{ .Env.DEPLOYMENT }}
- name: magnolia.superuser.enabled
value: "true"
- name: magnolia.superuser.password
value: "superuser!"
- name: magnolia.bootstrap.license.owner <1>
value: "[replace with email]"
- name: magnolia.bootstrap.license.key <1>
value: "[replace with key]"
setenv:
memory:
minPercentage: 25
maxPercentage: 60
rescueModeDX: False
catalinaExtraEnv:
magnolia.yaml.envsubst: "true"
resources:
requests:
memory: 4Gi
limits:
memory: 4Gi
logging:
level: DEBUG
pattern: '{"level":"%p","timestamp":"%d{ISO8601}","file":"%c:%L","message":"%m"}%n'
loggers:
- name: my-logger
level: ERROR
appenders:
- name: my-appender
tagName: CustomTag
properties:
key1: value1
key2: value2
key3: value3
livenessProbe:
enabled: true
path: "/.rest/status"
startupProbe:
enabled: True
failureThreshold: 90
periodSeconds: 10
persistence:
size: 10Gi
db:
tag: 15-alpine <2>
persistence:
size: "10Gi"
contentsync:
enabled: true
restore:
enabled: False
backup:
enabled: True
env:
- name: MGNLBACKUP_USE_PG_WAL
value: "true"
- name: MGNLBACKUP_SYNC_DIR
value: "/archive"
- name: MGNLBACKUP_NO_STDOUT
value: "true"
- name: MGNLBACKUP_LOGLEVEL
value: "debug"
- name: MGNLBACKUP_BUCKET
value: "paastraining-backup-bucket"
- name: MGNLBACKUP_PREFIX
value: "{{ .Env.DEPLOYMENT }}/author"
- name: MGNLBACKUP_CRON
value: "0 3 * * *"
- name: MGNLBACKUP_KEEPDAYS
value: "30"
- name: MGNLBACKUP_TAGS_RELEASE
value: {{ .Env.DEPLOYMENT }}
#
# Choose backup location based on cloud provider of the cluster
#
# Backup to S3
- name: MGNLBACKUP_S3_ENDPOINT
value: "s3.eu-central-1.amazonaws.com"
- name: MGNLBACKUP_S3_REGION
value: "eu-central-1"
- name: MGNLBACKUP_S3_ACCESSKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: accesskey
- name: MGNLBACKUP_S3_SECRETKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: secretkey
The license gets injected only when an environment gets created via the Helm chart, meaning this only happens once, when the environment is created. If you need to update your license, it should be handled directly in Magnolia.
The PostgreSQL version. This is for informational purposes only. You should not change this property.
Magnolia Author properties
| Property | Description |
|---|---|
enabled | Boolean that enables the author instance. If set to false, no author instance is deployed. |
restartPolicy | Should always be set to Always. |
redeploy | Boolean for redeploying the author instance if there is a change to the parent Helm chart. true = redeploys on helm upgrades even if no changes were made. false = does not redeploy on helm upgrades. |
contextPath | The context path for the instance. > IMPORTANT: You must always have a leading slash /. Example: /author |
base_url | The Magnolia base URL. Example: https://{{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io/ |
env | Magnolia environment configuration. Includes critical components like magnolia.bootstrap.license.owner and magnolia.bootstrap.license.key. See env license example below. |
rescueModeDX | Boolean to determine if rescue mode is enabled or not. Default: false. For more details, see Rescue app. |
catalinaExtraEnv | The environment variables that are added to CATALINA_OPTS (CATALINA_OPTS is an environment variable that allows you to specify options and arguments passed to the JVM when starting Tomcat). You can add your own environment variables here. See Configuration management: environment variables for more details. |
setenv | Under setenv, you should only configure the values for minPercentage and maxPercentage. These are the minimum (or maximum) percentage of pod memory allocated to the heap. > Tip: The heap is where Java objects and data structures are stored during runtime. |
resources | In the resources: section, you control how much memory is allocated to pod requests as well as set limits to the pod memory. This is measured in Gi (gibibytes) which is approximately 1.1 Gigabyte (GB). See resources example below. |
startupProbe | Readiness mechanism for applications that take a significant amount of time to start. See startupProbe example below. |
logging | Use this section to overwrite Tomcat logging lines. You can define the level such as DEBUG as well as set the pattern. Here, you can also define loggers and appenders. Do not log to files inside the container. Always log to stdout or stderr if possible or use a different log shipping mechanism. See logging example below. |
persistence | Sets the size of the Persistent Volume Claim (PVC) for the Magnolia Author instance. Ensure the allocated storage size aligns with your content and indexing requirements. > IMPORTANT: This is only applied during the initial deployment. After deployment, resizing must be done via the Rancher UI or by DevOps teams as shown in Troubleshooting: Magnolia persistent volume is almost full. |
db | The db section in your values.yml file defines critical database properties, including persistence size, backups, and content synchronization. These settings are applied during the initial deployment of your DX Cloud project. See db example below. |
env license example
...
- name: magnolia.bootstrap.license.owner <1>
value: "[replace with email]"
- name: magnolia.bootstrap.license.key <1>
value: "[replace with key]"
...
The license gets injected only when an environment gets created via the Helm chart, meaning this only happens once, when the environment is created. If you need to update your license, it should be handled directly in Magnolia.
resources example
resources:
requests:
memory: 4Gi <1>
limits:
memory: 4Gi <2>
Set the memory limit for pod requests.
Set the memory limit for the pod.
startupProbe example
startupProbe:
enabled: True
failureThreshold: 720 <1>
periodSeconds: 10 <2>
Increase failureThreshold (number of attempts before failing) to accommodate indexing time for large storage or migrating customers in order to avoid indexing failures.
periodSeconds defines the interval (in seconds) between each probe check.
In this example, the probe is checked every 10 seconds 720 times, meaning 2 hours (7200 seconds) before the application officially fails.
logging example
logging:
level: DEBUG <1>
pattern: "%d %-5p %-50.50c: %m%n" <2>
loggers: <3>
- name: my-logger
level: ERROR
appenders: <4>
- name: my-appender
tagName: CustomTag
properties:
key1: value1
key2: value2
key3: value3
Sets the logging level.
This is either INFO, WARN, ERROR, FATAL, OR DEBUG.
DEBUG is the most verbose, capturing the most granular details for logging purposes.
Defines the log message format.
Define additional loggers.
Define additional appenders with tagName and properties.
db example
The database persistence size (persistence.size) is set during the initial deployment of your DX Cloud project.
Once deployed, attempting to modify this value in subsequent deployments will result in an error.
If you need to increase or decrease the persistence size after the initial deployment, please contact Support.
Our team will assist you in making the necessary adjustments.
db:
tag: 15-alpine <1>
persistence:
size: "10Gi" <2>
contentsync:
enabled: true
restore:
enabled: False
backup: <3>
enabled: True
env:
- name: MGNLBACKUP_USE_PG_WAL
value: "true"
- name: MGNLBACKUP_SYNC_DIR
value: "/archive"
- name: MGNLBACKUP_NO_STDOUT
value: "true"
- name: MGNLBACKUP_LOGLEVEL
value: "debug"
- name: MGNLBACKUP_BUCKET <4>
value: "paastraining-backup-bucket"
- name: MGNLBACKUP_PREFIX
value: "{{ .Env.DEPLOYMENT }}/author"
- name: MGNLBACKUP_CRON
value: "0 3 * * *"
- name: MGNLBACKUP_KEEPDAYS
value: "30"
- name: MGNLBACKUP_TAGS_RELEASE
value: {{ .Env.DEPLOYMENT }}
#
# Choose backup location based on cloud provider of the cluster
#
# Backup to S3
- name: MGNLBACKUP_S3_ENDPOINT
value: "s3.eu-central-1.amazonaws.com"
- name: MGNLBACKUP_S3_REGION
value: "eu-central-1"
- name: MGNLBACKUP_S3_ACCESSKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: accesskey
- name: MGNLBACKUP_S3_SECRETKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: secretkey
The PostgreSQL version. This is for informational purposes only. You should not change this property.
Sets the volume size of the database.
10Gi is typically sufficient for a dev environment, 100Gi for production.
Defines that backups of the database are taken and stored to an S3 bucket or Azure storage (depending on your cloud provider) provisioned by Magnolia.
The value of MGNLBACKUP_BUCKET is provided to you by Magnolia.
Magnolia Public
The magnoliaPublic section of your values.yml file handles important configuration for the Magnolia Public instance.
The public instance is the publicly viewable instance for your site.
The properties shown in the example below are configurable.
magnoliaPublic:
enabled: true
restartPolicy: Always
redeploy: true
bootstrap:
password: superuser!
activation:
useExistingSecret: False
contextPath: /
base_url: https://{{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io/
sameSiteCookies: strict
env:
- name: instance
value: "public"
- name: deployment
value: {{ .Env.DEPLOYMENT }}
- name: magnolia.superuser.enabled
value: "true"
- name: magnolia.superuser.password
value: "superuser!"
- name: magnolia.bootstrap.license.owner <1>
value: "[replace with email]"
- name: magnolia.bootstrap.license.key <1>
value: "[replace with key]"
setenv:
memory:
minPercentage: 25
maxPercentage: 60
rescueModeDX: False
replicas: 2
catalinaExtraEnv:
magnolia.yaml.envsubst: "true"
resources:
requests:
memory: 4Gi
limits:
memory: 4Gi
logging:
level: DEBUG
pattern: '{"level":"%p","timestamp":"%d{ISO8601}","file":"%c:%L","message":"%m"}%n'
loggers:
- name: my-logger
level: ERROR
appenders:
- name: my-appender
tagName: CustomTag
properties:
key1: value1
key2: value2
key3: value3
livenessProbe:
enabled: true
path: "/.rest/status"
startupProbe:
enabled: True
failureThreshold: 90
periodSeconds: 10
persistence:
size: 10Gi
db:
tag: 15-alpine <2>
persistence:
size: "10Gi"
contentsync:
enabled: true
restore:
enabled: False
backup:
enabled: True
env:
- name: MGNLBACKUP_USE_PG_WAL
value: "true"
- name: MGNLBACKUP_SYNC_DIR
value: "/archive"
- name: MGNLBACKUP_NO_STDOUT
value: "true"
- name: MGNLBACKUP_LOGLEVEL
value: "debug"
- name: MGNLBACKUP_BUCKET
value: "paastraining-backup-bucket"
- name: MGNLBACKUP_PREFIX
value: "{{ .Env.DEPLOYMENT }}/public"
- name: MGNLBACKUP_CRON
value: "0 3 * * *"
- name: MGNLBACKUP_KEEPDAYS
value: "30"
- name: MGNLBACKUP_TAGS_RELEASE
value: {{ .Env.DEPLOYMENT }}
#
# Choose backup location based on cloud provider of the cluster
#
# Backup to S3
- name: MGNLBACKUP_S3_ENDPOINT
value: "s3.eu-central-1.amazonaws.com"
- name: MGNLBACKUP_S3_REGION
value: "eu-central-1"
- name: MGNLBACKUP_S3_ACCESSKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: accesskey
- name: MGNLBACKUP_S3_SECRETKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: secretkey
The license gets injected only when an environment gets created via the Helm chart, meaning this only happens once, when the environment is created. If you need to update your license, it should be handled directly in Magnolia.
The PostgreSQL version. This is for informational purposes only. You should not change this property.
Magnolia public properties
| Property | Description |
|---|---|
enabled | Boolean that enables the public instance. If set to false, no public instance is deployed. |
restartPolicy | Should always be set to Always. |
redeploy | Boolean for redeploying the public instance if there is a change to the parent Helm chart. true = redeploys on helm upgrades even if no changes were made. false = does not redeploy on helm upgrades. |
contextPath | The context path for the instance. > IMPORTANT: You must always have a leading slash /. Example: /public |
base_url | The Magnolia base URL. Example: https://{{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io/ |
env | Magnolia environment configuration. Includes critical components like magnolia.bootstrap.license.owner and magnolia.bootstrap.license.key. See Public env license example below. |
rescueModeDX | Boolean to determine if rescue mode is enabled or not. Default: false. For more details, see Rescue app. |
replicas | Defines how many public instances to deploy. You must scale up or down by changing the replicas value. You can do this in the values.yml file or in the Cockpit environments UI. > Note: One replica is sufficient for a dev environment, but a minimum of 2 is needed for production. |
catalinaExtraEnv | The environment variables that are added to CATALINA_OPTS (CATALINA_OPTS is an environment variable that allows you to specify options and arguments passed to the JVM when starting Tomcat). You can add your own environment variables here. See Configuration management: environment variables for more details. |
setenv | Under setenv, you should only configure the values for minPercentage and maxPercentage. These are the minimum (or maximum) percentage of pod memory allocated to the heap. > Tip: The heap is where Java objects and data structures are stored during runtime. |
resources | In the resources: section, you control how much memory is allocated to pod requests as well as set limits to the pod memory. This is measured in Gi (gibibytes) which is approximately 1.1 Gigabyte (GB). See Public resources example below. |
startupProbe | Readiness mechanism for applications that take a significant amount of time to start. See Public startupProbe example below. |
logging | Use this section to overwrite Tomcat logging lines. You can define the level such as DEBUG as well as set the pattern. Here, you can also define loggers and appenders. Do not log to files inside the container. Always log to stdout or stderr if possible or use a different log shipping mechanism. See Public logging example below. |
persistence | Sets the size of the Persistent Volume Claim (PVC) for the Magnolia Public instance. Ensure the allocated storage size aligns with your content and indexing requirements. > IMPORTANT: This is only applied during the initial deployment. After deployment, resizing must be done via the Rancher UI or by DevOps teams as shown in Troubleshooting: Magnolia persistent volume is almost full. |
db | The db section in your values.yml file defines critical database properties, including persistence size, backups, and content synchronization. These settings are applied during the initial deployment of your DX Cloud project. See Public db example below. |
Public env license example
...
- name: magnolia.bootstrap.license.owner <1>
value: "[replace with email]"
- name: magnolia.bootstrap.license.key <1>
value: "[replace with key]"
...
The license gets injected only when an environment gets created via the Helm chart, meaning this only happens once, when the environment is created. If you need to update your license, it should be handled directly in Magnolia.
Public resources example
resources:
requests:
memory: 4Gi <1>
limits:
memory: 4Gi <2>
Set the memory limit for pod requests.
Set the memory limit for the pod.
Public startupProbe example
startupProbe:
enabled: True
failureThreshold: 720 <1>
periodSeconds: 10 <2>
Increase failureThreshold (number of attempts before failing) to accommodate indexing time for large storage or migrating customers in order to avoid indexing failures.
periodSeconds defines the interval (in seconds) between each probe check.
In this example, the probe is checked every 10 seconds 720 times, meaning 2 hours (7200 seconds) before the application officially fails.
Public logging example
logging:
level: DEBUG <1>
pattern: "%d %-5p %-50.50c: %m%n" <2>
loggers: <3>
- name: my-logger
level: ERROR
appenders: <4>
- name: my-appender
tagName: CustomTag
properties:
key1: value1
key2: value2
key3: value3
Sets the logging level.
This is either INFO, WARN, ERROR, FATAL, OR DEBUG.
DEBUG is the most verbose, capturing the most granular details for logging purposes.
Defines the log message format.
Define additional loggers.
Define additional appenders with tagName and properties.
Public db example
The database persistence size (persistence.size) is set during the initial deployment of your DX Cloud project.
Once deployed, attempting to modify this value in subsequent deployments will result in an error.
If you need to increase or decrease the persistence size after the initial deployment, please contact Support.
Our team will assist you in making the necessary adjustments.
db:
tag: 15-alpine <1>
persistence:
size: "10Gi" <2>
contentsync:
enabled: true
restore:
enabled: False
backup: <3>
enabled: True
env:
- name: MGNLBACKUP_USE_PG_WAL
value: "true"
- name: MGNLBACKUP_SYNC_DIR
value: "/archive"
- name: MGNLBACKUP_NO_STDOUT
value: "true"
- name: MGNLBACKUP_LOGLEVEL
value: "debug"
- name: MGNLBACKUP_BUCKET <4>
value: "paastraining-backup-bucket"
- name: MGNLBACKUP_PREFIX
value: "{{ .Env.DEPLOYMENT }}/public"
- name: MGNLBACKUP_CRON
value: "0 3 * * *"
- name: MGNLBACKUP_KEEPDAYS
value: "30"
- name: MGNLBACKUP_TAGS_RELEASE
value: {{ .Env.DEPLOYMENT }}
#
# Choose backup location based on cloud provider of the cluster
#
# Backup to S3
- name: MGNLBACKUP_S3_ENDPOINT
value: "s3.eu-central-1.amazonaws.com"
- name: MGNLBACKUP_S3_REGION
value: "eu-central-1"
- name: MGNLBACKUP_S3_ACCESSKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: accesskey
- name: MGNLBACKUP_S3_SECRETKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: secretkey
The PostgreSQL version. This is for informational purposes only. You should not change this property.
Sets the volume size of the database.
10Gi is typically sufficient for a dev environment, 100Gi for production.
Defines that backups of the database are taken and stored to an S3 bucket or Azure storage (depending on your cloud provider) provisioned by Magnolia.
The value of MGNLBACKUP_BUCKET is provided to you by Magnolia.
Jars
If you need external JARs or libraries that should be packaged or made available to your DX Cloud project during runtime, you should add them to the jars: section of the values.yml file.
The following example shows how the PostgreSQL JDBC driver is loaded.
jars: <1>
- name: postgres-jdbc
repository: registry.gitlab.com/mironet/magnolia-jar/postgres-42.2.8
tag: v0.0.1
env:
- name: INIT_DEST <2>
value: /app/magnolia/WEB-INF/lib
initScript: /init.sh <3>
Add additional JARS in the jars: section.
Do not change any default JARS.
As of now the only tasks expected from init containers is to copy files to a target directory specified by the env var INIT_DEST.
This chart expects the init containers to contain an /init.sh script which is called as the only command.
Timezone
You can set the timezone for your Magnolia instances within the values.yml file.
timezone: Europe/Zurich <1>
Set the timezone for your Magnolia instances.
Tolerations
In Kubernetes, taints and tolerations work together to control which pods can run on which nodes. This mechanism helps ensure that certain nodes are reserved for particular workloads or types of workloads (e.g., critical system services, high-memory workloads, or databases).
Using DX Cloud Basic?
To ensure the Magnolia deployment uses dedicated nodes, you must configure tolerations and node affinity in your values.yml file:
## Add Toleration
tolerations: <1>
- key: dedicated
operator: Equal
value: prod
effect: PreferNoSchedule
## Node Affinity
nodeAffinity: <2>
preferredDuringSchedulingIgnoredDuringExecution:
- preference:
matchExpressions:
- key: dedicated
operator: In
values:
- prod
weight: 100
Allows a pod to be scheduled on a node with a matching taint. It specifies that the pod “tolerates” the node’s taint, enabling it to run even if the node is marked for a particular use case.
Defines the conditions under which a pod can be scheduled on a node based on labels.
This creates a preference (soft affinity) for nodes labeled with dedicated=prod.
Applying tolerations to frontend deployments
When using DX Cloud Basic with dedicated nodes, any frontend application that serves your Magnolia content must use the same tolerations and node affinity settings as your Magnolia instances.
This is because your frontend is part of the same production workload and needs to:
- Run on the dedicated production nodes alongside Magnolia
- Benefit from network locality with the Magnolia instances it communicates with
- Maintain the same isolation and resource guarantees
Frontend deployment example
apiVersion: apps/v1
kind: Deployment
metadata:
name: frontend-deployment
spec:
replicas: 1
selector:
matchLabels:
app: frontend
template:
metadata:
labels:
app: frontend
spec:
containers:
- name: frontend
image: your-frontend-image:latest
# [container configuration...]
# These must match your Magnolia values.yml settings
tolerations:
- key: dedicated <1>
operator: Equal
value: prod <2>
effect: PreferNoSchedule
affinity:
nodeAffinity: <3>
preferredDuringSchedulingIgnoredDuringExecution:
- preference:
matchExpressions:
- key: dedicated
operator: In
values:
- prod
weight: 100
The toleration key (dedicated) must exactly match what you configured in your values.yml file for Magnolia.
The value (prod) must exactly match what you configured in your values.yml file for Magnolia.
The nodeAffinity settings must exactly match what you configured in your values.yml file for Magnolia.
Reference file
This section contains a full example file for reference. When your project is created, a file similar to the following is generated.
The preceding specific sections are shown in full here in the sample values.yml file.
An example file is shown here.
ingress:
enabled: true
annotations:
kubernetes.io/ingress.class: "nginx"
nginx.ingress.kubernetes.io/proxy-body-size: 512m
cert-manager.io/cluster-issuer: "letsencrypt-prod"
#
# run author and public in different contexts and use the same domain name
# only one of these hosts/tls sections may be active
#
# hosts:
# - host: {{ .Env.DEPLOYMENT }}.paastraining.magnolia-platform.io
# paths:
# - path: /
# instance: public
# - path: /author
# instance: author
# tls:
# - hosts:
# - {{ .Env.DEPLOYMENT }}.paastraining.magnolia-platform.io
# secretName: {{ .Env.DEPLOYMENT }}-paastraining-magnolia-platform-io
#
# run author and public in ROOT context and use different domain names
# only one of these hosts/tls sections may be active
#
hosts:
- host: {{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io
paths:
- path: /
instance: author
port: https
- host: {{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io
paths:
- path: /
instance: public
port: https
# - host: {{ .Env.DEPLOYMENT }}.frontend-author.paastraining.magnolia-platform.io
# paths:
# - path: /
# instance: frontend-author
# - host: {{ .Env.DEPLOYMENT }}.frontend-public.paastraining.magnolia-platform.io
# paths:
# - path: /
# instance: frontend-public
tls:
- hosts:
- {{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io
- {{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io
# - {{ .Env.DEPLOYMENT }}.frontend-author.paastraining.magnolia-platform.io
# - {{ .Env.DEPLOYMENT }}.frontend-public.paastraining.magnolia-platform.io
secretName: {{ .Env.DEPLOYMENT }}-paastraining-magnolia-platform-io
image:
pullSecrets:
- name: gitlab
pullPolicy: Always
magnoliaAuthor:
enabled: true
restartPolicy: Always
redeploy: true
bootstrap:
password: superuser!
activation:
useExistingSecret: False
#
# run author and public in different contexts and use the same domain name
# only one of these contextPath/base_url values may be active
#
# contextPath: /author
# base_url: https://{{ .Env.DEPLOYMENT }}.paastraining.magnolia-platform.io/author
#
# run author and public in ROOT context and use different domain names
# only one of these contextPath/base_url values may be active
#
contextPath: /
base_url: https://{{ .Env.DEPLOYMENT }}.author.paastraining.magnolia-platform.io/
sameSiteCookies: strict
webarchive:
repository: {{ .Env.CI_REGISTRY_IMAGE }}/magnolia-webapp
tag: {{ .Env.GIT_TAG | quote }}
env:
- name: instance
value: "author"
- name: deployment
value: {{ .Env.DEPLOYMENT }}
- name: magnolia.superuser.enabled
value: "true"
- name: magnolia.superuser.password
value: "superuser!"
- name: magnolia.bootstrap.license.owner
value: "[replace with email]"
- name: magnolia.bootstrap.license.key
value: "[replace with key]"
setenv:
memory:
maxPercentage: 80
resources:
requests:
memory: 4Gi
limits:
memory: 4Gi
livenessProbe:
enabled: true
path: "/.rest/status"
db:
tag: 15-alpine
persistence:
size: "10Gi"
contentsync:
enabled: true
restore:
enabled: False
backup:
enabled: True
env:
- name: MGNLBACKUP_USE_PG_WAL
value: "true"
- name: MGNLBACKUP_SYNC_DIR
value: "/archive"
- name: MGNLBACKUP_NO_STDOUT
value: "true"
- name: MGNLBACKUP_LOGLEVEL
value: "debug"
- name: MGNLBACKUP_BUCKET
value: "paastraining-backup-bucket"
- name: MGNLBACKUP_PREFIX
value: "{{ .Env.DEPLOYMENT }}/author"
- name: MGNLBACKUP_CRON
value: "0 3 * * *"
- name: MGNLBACKUP_KEEPDAYS
value: "30"
- name: MGNLBACKUP_TAGS_RELEASE
value: {{ .Env.DEPLOYMENT }}
#
# Choose backup location based on cloud provider of the cluster
#
# Backup to S3
- name: MGNLBACKUP_S3_ENDPOINT
value: "s3.eu-central-1.amazonaws.com"
- name: MGNLBACKUP_S3_REGION
value: "eu-central-1"
- name: MGNLBACKUP_S3_ACCESSKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: accesskey
- name: MGNLBACKUP_S3_SECRETKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: secretkey
# Backup to Azure storage
# - name: MGNLBACKUP_AZ_ACCOUNT_NAME
# valueFrom:
# secretKeyRef:
# name: az-backup-key
# key: AccountName
# - name: MGNLBACKUP_AZ_ACCOUNT_KEY
# valueFrom:
# secretKeyRef:
# name: az-backup-key
# key: AccountKey
magnoliaPublic:
enabled: true
replicas: 1
restartPolicy: Always
bootstrap:
password: superuser!
activation:
useExistingSecret: False
contextPath: /
#
# run author and public in different contexts and use the same domain name
# only one of these base_url values may be active
#
# base_url: https://{{ .Env.DEPLOYMENT }}.paastraining.magnolia-platform.io/
#
# run author and public in ROOT context and use different domain names
# only one of these base_url values may be active
#
base_url: https://{{ .Env.DEPLOYMENT }}.public.paastraining.magnolia-platform.io/
sameSiteCookies: strict
webarchive:
repository: {{ .Env.CI_REGISTRY_IMAGE }}/magnolia-webapp
tag: {{ .Env.GIT_TAG | quote }}
env:
- name: instance
value: "public"
- name: deployment
value: {{ .Env.DEPLOYMENT }}
- name: magnolia.superuser.enabled
value: "true"
- name: magnolia.superuser.password
value: "superuser!"
- name: magnolia.bootstrap.license.owner
value: "[replace with email]"
- name: magnolia.bootstrap.license.key
value: "[replace with key]"
setenv:
memory:
maxPercentage: 80
resources:
requests:
memory: 4Gi
limits:
memory: 4Gi
livenessProbe:
enabled: true
path: "/.rest/status"
db:
tag: 15-alpine
persistence:
size: "10Gi"
contentsync:
enabled: true
restore:
enabled: False
backup:
enabled: True
env:
- name: MGNLBACKUP_USE_PG_WAL
value: "true"
- name: MGNLBACKUP_SYNC_DIR
value: "/archive"
- name: MGNLBACKUP_NO_STDOUT
value: "true"
- name: MGNLBACKUP_LOGLEVEL
value: "debug"
- name: MGNLBACKUP_BUCKET
value: "paastraining-backup-bucket"
- name: MGNLBACKUP_PREFIX
value: "{{ .Env.DEPLOYMENT }}/public"
- name: MGNLBACKUP_CRON
value: "0 3 * * *"
- name: MGNLBACKUP_KEEPDAYS
value: "30"
- name: MGNLBACKUP_TAGS_RELEASE
value: {{ .Env.DEPLOYMENT }}
#
# Choose backup location based on cloud provider of the cluster
#
# Backup to S3
- name: MGNLBACKUP_S3_ENDPOINT
value: "s3.eu-central-1.amazonaws.com"
- name: MGNLBACKUP_S3_REGION
value: "eu-central-1"
- name: MGNLBACKUP_S3_ACCESSKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: accesskey
- name: MGNLBACKUP_S3_SECRETKEY
valueFrom:
secretKeyRef:
name: s3-backup-key
key: secretkey
# Backup to Azure storage
# - name: MGNLBACKUP_AZ_ACCOUNT_NAME
# valueFrom:
# secretKeyRef:
# name: az-backup-key
# key: AccountName
# - name: MGNLBACKUP_AZ_ACCOUNT_KEY
# valueFrom:
# secretKeyRef:
# name: az-backup-key
# key: AccountKey
# Additional jars which should be loaded into tomcat can be specified here.
jars:
- name: jmx-exporter
repository: registry.gitlab.com/mironet/magnolia-jar
tag: jmx_prometheus_javaagent-0.13.0
env:
- name: INIT_DEST
value: /extraLibs/
initScript: /init.sh
# -- Node Toleration for Magnolia Workload.
# Add Toleration
tolerations: []
# - key: dedicated
# operator: Equal
# value: prod
# effect: PreferNoSchedule
# -- Schedule Magnolia to labeled nodes, considering [nodeAffinity expressions](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity) (may interfere with 'nodeSelector').
nodeAffinity: {}
# # Example Hard Node Affinity:
# nodeAffinity:
# requiredDuringSchedulingIgnoredDuringExecution:
# nodeSelectorTerms:
# - matchExpressions:
# - key: dedicated
# operator: In
# values:
# - MagnoliaNode
# # Example Soft Node Affinity:
# nodeAffinity:
# preferredDuringSchedulingIgnoredDuringExecution:
# - preference:
# matchExpressions:
# - key: dedicated
# operator: In
# values:
# - MagnoliaNode
# weight: 100