Skip to navigation

Config Manager Temporal Deployment Process

View as MarkdownOpen in Claude

Temporal is deployed as part of the Config Manager Helm release. Use the standard deployment guide for connected environments and the airgapped deployment guide for disconnected environments.

Deployment Inputs

The installer controls Temporal deployment through nv-config-manager-install.yaml and generated Helm values:

  • services.temporal: enables the Temporal API, workers, and related deployment resources.
  • temporal.history_replicas: optionally overrides the managed History service pod count.
  • temporal.num_history_shards: optionally overrides the persisted History shard count.
  • temporal.failed_stage_retry_timeout_seconds: optionally overrides the failed-stage retry window.
  • cluster.hostname: drives public workflow API and Temporal Web hostnames.
  • secrets: provides database, auth, and integration secrets.
  • rbac: configures workflow read and execute roles.
  • infrastructure: configures TLS, gateway, storage, and optional observability.

Workflow attribution domain

Authenticated email identities supply their own domain for new workflow attribution. When an authenticated identity is a short username or service name, configure an optional deployment default:

global:
defaultUserDomain: example.com

The setting is used for backend workflow attribution; it is not a UI display setting. The chart writes it to [temporal].user_domain in the unified nv-config-manager.ini and passes it to the Temporal API, worker, and Render workloads as NV_CONFIG_MANAGER_DOMAIN. For deployments that do not use this Helm chart, set the INI value for Temporal clients and NV_CONFIG_MANAGER_DOMAIN for those processes. If it is unset, the Workflow API leaves nullable user_domain fields as None and rejects unresolved non-nullable fields with 422. Explicit caller-owned domain values are preserved, while fields declared ServerOwned are always replaced by authenticated attribution.

History Shards and Replicas

In nv-config-manager-install.yaml, leave the Temporal sizing values unset or set them to 0 to use the deployment size profile and chart defaults. Set positive values to configure a new managed Temporal cluster explicitly:

services:
temporal: true
temporal:
history_replicas: 16
num_history_shards: 128

The installer maps temporal.num_history_shards to temporal.numHistoryShards, which initializes the persisted History shard count when Temporal creates the cluster. Legacy deployments that leave temporal.numHistoryShards unset initialize that count from the then-current temporal.services.history.replicas value.

Before scaling History replicas, confirm the existing persisted shard count and set temporal.numHistoryShards (or the installer temporal.num_history_shards) to that value. Pinning the value does not modify an initialized cluster; it keeps the declared configuration aligned with the persisted count. If the shard count itself must change, follow an approved shard migration procedure instead.

The installer maps temporal.history_replicas to the Helm value temporal.services.history.replicas. This controls the number of History service pods. Each History pod processes only the shards it owns, so the shard count limits useful History replicas. With the default four shards, at most four pods own shards; additional replicas add no shard-processing capacity. Choose a shard count that covers the largest planned History replica count before Temporal initializes the cluster. See Temporal’s History shards architecture notes for the deployed server version.

After the shard count is pinned, History replicas can be adjusted as load changes, up to the shard count. The equivalent direct Helm override is:

temporal:
numHistoryShards: 128
services:
history:
replicas: 16

Temporal ignores changes to temporal.numHistoryShards after the cluster’s first run and continues using the original persisted shard count. Changing only the Helm or installer value does not re-shard an initialized cluster. Temporal does not provide an in-place re-sharding command; do not attempt to work around this by editing cluster metadata or restoring the database under a different shard count.

Failed-Stage Retry Window

Configure the manual retry window after an activity or child workflow exhausts its automatic retries. The default is three hours. In nv-config-manager-install.yaml, omit the setting or set it to 0 to keep the default:

temporal:
failed_stage_retry_timeout_seconds: 7200 # Two hours

Unlike the History sizing fields, this setting also applies when Temporal is external, because the workflow API, scheduler, and workers still run in this deployment. The installer maps it to the Helm value temporal.configManagerWorker.failedStageRetryTimeoutSeconds. The equivalent direct Helm override is:

temporal:
configManagerWorker:
failedStageRetryTimeoutSeconds: 7200

The Helm value must be a positive integer in seconds, up to 31536000 (365 days). The chart rejects 0, negative, non-integer, and oversized values instead of disabling the cap; only the installer treats 0 as “use the default”. If the key is unset or null, for example after helm upgrade --reuse-values from a release that predates it, the chart renders the three-hour default. The value is written to [temporal.worker].failed_stage_retry_timeout_seconds in the unified INI for Kubernetes Secrets, ESO, and Vault Agent deployments.

The workflow API and scheduler read the current INI each time they start a workflow or create a schedule, so a change applies to workflows and schedules created after the updated INI reaches those pods. They record the setting in each new workflow or schedule action. Children and continue-as-new runs inherit it from the parent history, so a worker restart or configuration update cannot alter a recorded retry window. Existing schedules keep their recorded value until recreated; workflows started without this setting in history retain the three-hour default. Existing histories already waiting on the legacy indefinite retry path remain on that path.

This setting does not impose a total workflow run timeout or limit healthy work and approval waits. When an unanswered failure wait expires, the workflow closes as Failed with a StageRetryTimeout cause. Existing shorter run or execution deadlines continue to apply. See Workflow Lifecycle.

Worker Cache and Task Limits

The Config Manager worker limits its sticky workflow cache and concurrent workflow tasks to bound memory use during large workflow batches. Configure the limits directly in Helm values:

temporal:
configManagerWorker:
maxCachedWorkflows: 200
maxConcurrentWorkflowTasks: 10

The installer configuration does not expose these worker limits or temporal.dynamicConfig. Maintain overrides in a Helm values file applied after generated values in your Helm or GitOps workflow. nvcm-installer deploy regenerates values without that file and can reset these settings.

These are the Config Manager defaults, replacing the Temporal SDK defaults of 1,000 cached workflows and 100 concurrent workflow tasks. Each worker process reads the values at startup. Helm rolls the worker pods when these settings change; existing workflow histories stay in Temporal. For deployments outside Helm, restart workers after changing their configuration.

For deployments outside Helm, set max_cached_workflows and max_concurrent_workflow_tasks in the [temporal.worker] INI section. The cache must be a nonnegative integer; 0 disables it. Task concurrency must be a positive integer and at least 2 while the cache is enabled. Invalid values stop worker startup. Size the cache against each worker’s memory limit. Workflow-task slots limit workflow execution tasks, rather than the number of open workflows or activity executions.

Custom workflow plugins should follow the workflow module import pattern to share deterministic dependencies with the worker instead of re-importing them in every cached sandbox.

Server Dynamic Configuration

For the managed Temporal server, temporal.dynamicConfig uses Temporal’s native map of configuration keys to lists of values. For example:

temporal:
dynamicConfig:
frontend.namespaceRPS.visibility:
- value: 50
- value: 25
constraints:
namespace: example-namespace

The chart writes this structure directly to dynamic_config.yaml, preserving each value and its constraints. Do not wrap the map in another value key. The example sets a per-frontend visibility limit of 50 requests per second per Temporal namespace, with 25 for example-namespace. Other server rate limits can also apply. The namespace is a Temporal namespace, not a Kubernetes namespace; replace it with the namespace used by your workflows. When using an external Temporal server, configure dynamic settings on that server.

Temporal Images

The managed Temporal deployment uses three independently scoped distroless images:

Image keyPurposeOverride policy
temporalServerTemporal server rolesCompatible upstream or locally built images are supported. Keep the server version compatible with the bundled bootstrap schema.
temporalBootstrapDatabase schema setup, namespace creation, and search-attribute registrationProject-owned. It contains the version-matched Temporal schema, CLI tools, and NVIDIA Config Manager bootstrap binary. Mirror it through images.registry for private or airgapped registries; do not set a per-image override.
temporalUiTemporal Web UICompatible upstream or locally built images are supported. The UI version does not alter Temporal persistence.

For a user-managed remote Temporal service, configure the external Temporal connection instead. The chart does not run the server, UI, database schema, namespace, or search-attribute bootstrap workloads in that mode.

Upgrading from Temporal 1.30.8 to 1.31.5

Upgrade the server and bootstrap images together. Temporal 1.31 requires PostgreSQL core schema 1.19 and visibility schema 1.14. The chart’s frontend schema-setup init container runs the matching bootstrap image to update both databases before that frontend starts. The same images are built for Kind integration testing.

The 1.31.5 security patch includes Go’s compromised-CA distrust fix for CVE-2026-111943. The matching bootstrap image includes Temporal CLI 1.10.0. Upgrading from 1.31.4 keeps the same PostgreSQL schema versions. With Temporal’s default authorizer enabled, this patch requires namespace write permission for ValidateWorkerDeploymentVersionComputeConfig. The managed chart leaves Temporal gRPC authorization unset, which selects its no-op authorizer; workflow read/execute roles are enforced separately by Config Manager’s workflow API. The chart’s role mappings therefore need no change. Operators of external Temporal servers with authorization enabled must review their caller roles. See the Temporal 1.31.5 release notes.

The container build checks the copied server and admin-tool binaries’ Go build metadata. It accepts patched Go 1.26 and 1.27 releases, including experiment suffixes, and rejects prereleases or unknown versions. A future Go release series requires reviewing the build guard when updating the image pins. CI regression tests cover the minimum patch versions and rejected metadata; image builds check the actual upstream executables.

Before upgrading, take recoverable backups of both databases. After deployment, check the frontend’s schema-setup logs and confirm both schema_version tables report the required versions. The other server roles can restart while the frontend applies the migration; their TCP wait does not prove the new schema has finished applying during a rolling upgrade.

Rolling back the images does not undo database migrations. Keep new CHASM applications and standalone activities disabled while rollback to 1.30.8 is required; restoring database backups is a separate recovery operation. See the Temporal 1.31 release notes and server upgrade guide.

Verify Temporal

After deployment, verify the workflow API and Temporal Web routes:

kubectl get pods -n <namespace> | grep temporal
kubectl get httproutes -n <namespace> | grep -E 'workflow|temporal'

Open the workflow API at https://workflow.<hostname>/docs and Temporal Web at https://temporal.<hostname> if Temporal Web is enabled for the environment.

Operations

For normal operator actions, use the Config Manager UI. Use Temporal Web for detailed workflow event history, retries, payload inspection, and child workflow troubleshooting. See Which Interface Should I Use?.

Workflow Plugins

Set temporal.workflowPlugins.enabled to install workflow plugins without rebuilding the service image. This needs a service image from NVCM 1.4.0 or later. The worker, the workflow API, the scheduler host, and the MCP server each install the same plugins in init containers, because each builds the workflow registry at startup.

Each plugin ships as an image that holds the plugin wheel under /plugin-wheels:

temporal:
workflowPlugins:
enabled: true
images:
- name: acme
image: registry.example.com/acme-workflows@sha256:<digest>
- name: contoso
image: registry.example.com/contoso-workflows@sha256:<digest>
rbac:
- name: AcmeWorkflow
read_roles: [all]
execute_roles: [network-admin]

Three init containers run in order:

  1. A copy container per plugin image puts its wheels into a shared volume.
  2. install-workflow-plugins installs them with pip install --no-index --no-deps into /opt/workflow-plugins, which the process adds to PYTHONPATH.
  3. verify-workflow-plugins runs in the service image. It fails the pod before the main container starts when a wheel shadows a package or top-level module in the service image, when no wheel declares an nv_config_manager.workflows entry point, when the service image predates plugin support, or when the registry cannot load a declared plugin. It also sees /opt/dcim-providers when dcim.providerPackages is enabled.

All three init containers run as a non-root user with all capabilities dropped.

Include a wheel only for the plugin and for dependencies the service image lacks. Packages that ship in the service image, such as nv-config-manager-workflows, must not appear in the plugin image, or the verify step rejects them.

Plugin code runs in the worker and API with their credentials and access to Nautobot and devices. Pin plugin images by digest and review them as you would platform code.

Every plugin workflow that has an API endpoint needs a row, or its endpoint returns 403. List the rows under temporal.workflowPlugins.rbac. The chart appends them to rbac.workflows and rolls the API and scheduler pods when they change. A row that repeats a name already in rbac.workflows fails the render. rbac must be set, because the plugin rows add to the platform rows and do not replace them.

Verify that all four processes loaded the same plugins by comparing the Workflow registry manifest fingerprint in their logs:

for component in temporal-api temporal-nv-config-manager-worker temporal-scheduler mcp; do
kubectl logs -n <namespace> deploy/<release>-$component | grep -E 'Loaded workflow plugin|Workflow registry manifest'
done

Workflow Schedulers

The <release>-temporal-scheduler Deployment runs the scheduler host. The host discovers every scheduler contributed by the built-in workflows package and installed workflow plugins, then runs only the schedulers selected in Helm values. Installing or upgrading a plugin never starts a scheduler on its own.

Each scheduler has a stable identity of the form <plugin-name>.<name>, such as builtin.backup for the built-in backup scheduler or acme.cleanup for a scheduler from a plugin named acme. Every dot-separated segment starts with a lowercase letter and contains only lowercase letters, digits, underscores, or hyphens. The first segment must be the contributing plugin’s name, so plugins cannot claim each other’s identities, and the builtin. prefix is reserved for built-in schedulers. A plugin that contributes schedulers also cannot have a name starting with backup-, which is reserved for the built-in backup scheduler’s schedule IDs; identities such as acme.backup are allowed. The workflows package README lists accepted and rejected examples for plugin authors. The workflow API, the workflow worker, the scheduler host, and the MCP server each build the full workflow registry at startup, so a plugin or scheduler that breaks these rules, or any other plugin discovery or validation error, stops all of them from starting, even if the scheduler is not enabled.

Schedulers are enabled per stable identity under temporal.scheduler.schedulers. The chart default enables the built-in backup scheduler for the nautobot-2x DCIM provider:

temporal:
scheduler:
enabled: true
schedulers:
builtin.backup:
enabled: true
requiresDcimProvider: nautobot-2x

Helm merges maps across values files, so an environment lists only the entries it changes. To run a plugin scheduler in addition to the built-in backup scheduler:

temporal:
scheduler:
schedulers:
acme.cleanup:
enabled: true

To restrict a plugin scheduler to one DCIM provider, set requiresDcimProvider on its entry. Helm selects the entry only when dcim.provider matches:

temporal:
scheduler:
schedulers:
acme.cleanup:
enabled: true
requiresDcimProvider: nautobot-2x

To stop reconciling device backup schedules:

temporal:
scheduler:
schedulers:
builtin.backup:
enabled: false

Turning off builtin.backup, here or with temporal.scheduler.enabled: false, does not delete its existing backup-<device-id> schedules, which keep starting a backup for each device every 12 hours. Delete them in Temporal Web or with the Temporal CLI, for example temporal schedule delete --schedule-id backup-<device-id>.

Identities contain dots, so escape them when using --set:

helm upgrade <release> <chart> --reuse-values \
--set 'temporal.scheduler.schedulers.builtin\.backup.enabled=false'

Selection rules:

  • builtin.backup keeps a Temporal schedule backup-<device-id> for every backup-enabled device, runs each backup every 12 hours with up to one hour of jitter, and reconciles the device set every 10 minutes. Its default entry declares requiresDcimProvider: nautobot-2x, so by default Helm deploys it only on Nautobot. The scheduler host does not check the DCIM provider. If you set requiresDcimProvider: null on this entry, Helm deploys the backup scheduler and it runs against the configured DCIM provider, which must list backup-enabled devices. Listing backup-enabled devices is part of the required DCIM client interface.
  • Each entry must be a map with a boolean enabled flag. The optional requiresDcimProvider must be a non-empty string; otherwise rendering fails. Set requiresDcimProvider: null to remove a requirement inherited from the chart defaults, which makes the entry run on any provider; it does not turn the scheduler off. Use enabled: false for that.
  • Helm selects an entry when enabled is true and its requiresDcimProvider, if set, matches dcim.provider.
  • The Deployment is rendered only when at least one scheduler is selected. Installs on a DCIM provider other than nautobot-2x that enable no plugin schedulers have no scheduler pod.
  • On nautobot-2x, the pod waits for Nautobot before starting only when a builtin. scheduler is selected. A plugin-only pod skips this wait. Public runtime DCIM access is available to plugins; only the built-in scheduler adapter is configured conditionally. A plugin that uses DCIM must handle its unavailability during startup and operation.
  • If an existing release was installed from a chart that predates temporal.scheduler.schedulers, helm upgrade --reuse-values reuses values with no schedulers map, so rendering fails with temporal.scheduler.schedulers is missing before anything is applied; the running release is untouched. Upgrade without --reuse-values, or also pass --set 'temporal.scheduler.schedulers.builtin\.backup.enabled=true' --set 'temporal.scheduler.schedulers.builtin\.backup.requiresDcimProvider=nautobot-2x' to keep the chart default. Pass both: reused values have no default to merge, so without requiresDcimProvider the backup scheduler would also be deployed for other DCIM providers. To run no schedulers, set temporal.scheduler.enabled=false. The check fires only when the map is missing: if the same upgrade sets any other entry, such as --set 'temporal.scheduler.schedulers.acme\.cleanup.enabled=true', the map exists without builtin.backup, so rendering succeeds and backup reconciliation silently stops. Pass both builtin.backup settings in that case too.
  • A selected identity that no installed plugin provides stops the scheduler host at startup with Unknown enabled workflow scheduler identities.
  • The host constructs every selected scheduler before starting any. If a constructor raises, the host logs Failed to construct workflow scheduler <identity> from plugin <plugin> and exits nonzero before any scheduler runs. On SIGTERM or SIGINT, the host logs Received signal <signal>, stopping workflow schedulers, cancels every scheduler, and exits 0.
  • Selected schedulers share one pod and fail together. If any scheduler raises an unhandled exception or returns, the host stops every other scheduler, including builtin.backup, and exits nonzero so that Kubernetes restarts the pod. The Workflow scheduler <identity> from plugin <plugin> failed or ... returned unexpectedly log message names the failing scheduler; set its entry to enabled: false to keep the others running.
  • temporal.scheduler.enabled: false removes the Deployment entirely.
  • The host reads NVCM_ENABLED_SCHEDULERS as a comma-separated list of identities, which Helm sets from the selected entries. An identity listed more than once stops the scheduler host at startup with NVCM_ENABLED_SCHEDULERS contains a scheduler identity more than once. When you run nv-config-manager-temporal-scheduler directly, outside Helm, and the variable is unset, the host runs builtin.backup against the configured DCIM provider. If it is set to an empty value, the host runs no schedulers, logs a warning, and waits for shutdown.

The host logs the workflow plugin manifest and the selected scheduler identities at startup:

kubectl logs -n <namespace> deploy/<release>-temporal-scheduler | grep -E 'Loaded workflow plugin|Workflow registry manifest|Enabled workflow schedulers'

Worker Reliability

PodDisruptionBudgets

Two PDBs protect Temporal worker pods from simultaneous eviction during voluntary node disruptions (cluster upgrades, autoscaler scale-downs, scheduled maintenance):

PDB nameProtectsmaxUnavailable
<release>-temporal-worker-pdbTemporal server worker role1
<release>-temporal-nv-config-manager-worker-pdbnv-config-manager workflow executor1

With maxUnavailable: 1 and 3 replicas, the Kubernetes eviction API will allow at most one replica to be unavailable at any time. A node drain will block on the second eviction attempt until the first rescheduled pod is Ready.

To inspect the current disruption budget:

kubectl get pdb -n <namespace>
# NAME MIN AVAILABLE MAX UNAVAILABLE ALLOWED DISRUPTIONS
# <release>-temporal-worker-pdb N/A 1 1
# <release>-temporal-nv-config-manager-worker-pdb N/A 1 1

ALLOWED DISRUPTIONS shows how many more pods can be evicted within the disruption budget. With all three replicas Ready and maxUnavailable: 1, it shows 1. If it shows 0 at any point, check pod readiness and the PDB status before draining further nodes. Refer to the Kubernetes PodDisruptionBudget reference for details.

Pod Anti-Affinity

Both worker Deployments use preferredDuringSchedulingIgnoredDuringExecution pod anti-affinity with topology key kubernetes.io/hostname. The scheduler will prefer placing replicas on separate nodes. In clusters with fewer nodes than replicas the constraint degrades gracefully — pods still schedule, but may co-locate.

To verify replicas are spread across nodes:

# Temporal server worker
kubectl get pods -n <namespace> \
-l app.kubernetes.io/component=temporal-worker \
-o wide
# NODE column should show distinct hostnames across all 3 replicas
# nv-config-manager workflow executor
kubectl get pods -n <namespace> \
-l app.kubernetes.io/component=nv-config-manager-worker \
-o wide
# NODE column should show distinct hostnames across all 3 replicas