Manually manage the analyzer
The trace analyzer runs as the instruction-hub-worker service in your infrastructure. It receives traces from enrolled hosts, stores them in your PostgreSQL database and trace bucket, and analyzes sessions using your chosen model provider.
This guide uses worker chart 0.3.0 for operator-managed releases. The published chart pins its worker image by digest. Your operations team schedules and applies each upgrade. For automatic updates with pause and version-pin controls, use the default Helm installation.
Before you begin
Section titled “Before you begin”Complete the deployment planning checklist. You need:
- An existing Kubernetes cluster, Helm 3, and
kubectlconfigured for that cluster. - The public worker chart, a deployment install token beginning with
plih_, a deployment instance ID, and a configuration hash from Promptless. Obtain these registration values from Promptless. - A dedicated PostgreSQL database with its trusted CA bundle and a TLS connection string that verifies the server hostname. The database user needs schema migration permissions.
- An S3 bucket, Azure Blob container, or Google Cloud Storage bucket, with read and write access through workload identity.
- An existing ServiceAccount named
pig-analyzerin namespacepig, bound to that identity. Both the analyzer and migration Job use it. - A reachable HTTPS hostname, a certificate, and an existing ingress controller or equivalent route to the worker Service on port 8080.
- A GitHub Instruction Hub, its numeric repository ID, and credentials for repository access and your analysis model.
The complete example below uses Acme’s private GitHub hub and S3 on EKS. For AKS or GKE, substitute the native storage and identity settings in the manual Helm reference. The cloud deployment guides cover the infrastructure requirements.
Allow worker egress to PostgreSQL, your object store, Promptless, GitHub, and the model endpoint. Nodes also need container-registry access. See network and data boundaries.
Install the analyzer
Section titled “Install the analyzer”-
Prepare the namespace, identity, and secrets. Confirm the cluster you intend to change:
Terminal window kubectl config current-contextkubectl create namespace pig --dry-run=client -o yaml | kubectl apply -f -Create the
pig-analyzerServiceAccount through your platform or GitOps workflow before installing Helm. For the EKS example, bind its namespace and name in the IAM trust policy and apply this manifest, replacing the role ARN:service-account.yaml apiVersion: v1kind: ServiceAccountmetadata:name: pig-analyzernamespace: pigannotations:eks.amazonaws.com/role-arn: arn:aws:iam::123456789012:role/acme-pig-workerCreate a ConfigMap named
postgres-cainpigwith your database provider’s trusted CA bundle under the keyca.pem. The chart mounts it in both the analyzer and migration Job. Usesslmode=verify-fullin the PostgreSQL DSN.Create a Secret named
acme-pig-workerinpigthrough your secret-management system. It must contain these keys:Key Value install-tokenDeployment credential supplied by Promptless. This is separate from a host enrollment credential. customer-postgres-dsnPostgreSQL connection string, including the TLS settings your database requires. analysis-model-api-keyAPI key for the model endpoint in the next step. analysis-repository-tokenGitHub credential scoped to the Instruction Hub. For a manual pilot, run the following in Bash. It prompts without echoing credentials, creates the Secret, and removes its temporary file. Keep credentials out of committed manifests and values files.
Terminal window bash <<'BASH'set -euumask 077secret_file=$(mktemp)trap 'rm -f "$secret_file"' EXITfor key in install-token customer-postgres-dsn analysis-model-api-key analysis-repository-token; doread -r -s -p "$key: " secret_value </dev/ttyprintf '\n' >/dev/ttyprintf '%s=%s\n' "$key" "$secret_value" >>"$secret_file"doneunset secret_valuekubectl --namespace pig create secret generic acme-pig-worker \--from-env-file="$secret_file" --dry-run=client -o yaml | kubectl apply -f -BASHFor a private hub, the analysis repository token needs read access so the worker can clone and refresh its mirror. Promptless separately needs a repository connection for finding issues. It provides a scoped GitHub credential when a remediation task must push a branch and open a pull request. Coordinate that connection during deployment registration; a working clone alone does not prove both paths are configured.
-
Configure the worker. Save this as
values.yaml. Replace everyREPLACE_value and the hostname with your environment’s values. Get the numeric repository ID withgh api repos/acme/acme-instruction-hub --jq .idusing an account that can read the hub. Choose a model name your provider account can use.values.yaml secrets:existingSecretName: acme-pig-workerinstallTokenKey: install-tokencustomerPostgresDsnKey: customer-postgres-dsnanalysisModelApiKeyKey: analysis-model-api-keyanalysisRepositoryTokenKey: analysis-repository-tokeninstructionHub:runtimeBaseUrl: https://runtime.gopromptless.aideploymentName: acme-productiondeploymentInstanceId: REPLACE_DEPLOYMENT_INSTANCE_IDconfigHash: REPLACE_CONFIG_HASHstorageBackend: postgres_s3postgresCaConfigMapName: postgres-capostgresCaConfigMapKey: ca.pemtraceObjectS3Bucket: REPLACE_GLOBALLY_UNIQUE_BUCKETtraceObjectS3Prefix: acme/tracesanalysis:activationAt: "2026-09-14T00:00:00Z"quietWindowHours: 0.5modelApi:provider: openaiauthentication: api_keybaseUrl: https://api.openai.com/v1model: REPLACE_MODEL_NAMErepository:url: https://github.com/acme/acme-instruction-hub.gitid: 123456789fullName: acme/acme-instruction-hubtokenSecretEnabled: trueserviceAccount:create: falsename: pig-analyzermigrationJob:serviceAccountName: pig-analyzergateway:enabled: trueclassName: nginxannotations:nginx.ingress.kubernetes.io/proxy-body-size: "10m"hosts:- host: traces.acme.exampletls:- secretName: acme-pig-tlshosts:- traces.acme.exampleresources:requests:cpu: 500mmemory: 1Gilimits:memory: 2GiReplace
repository.id: 123456789with Acme’s actual repository ID. SetactivationAtto your chosen analysis start time; use a timezone-aware timestamp. The half-hour quiet window gives sessions time to finish before analysis. These resource values are a starting allocation: adjust them after measuring representative sessions.The example assumes an existing NGINX IngressClass named
nginx, a TLS Secret namedacme-pig-tlsinpig, and DNS pointing to that ingress. Setgateway.classNameto your controller’s class. If your platform manages the route separately, setgateway.enabled: falseand route HTTPS traffic toinstruction-hub-workerinpigon port 8080.The NGINX annotation permits trace uploads up to 10 MiB. Configure every ingress, load balancer, and proxy on the upload path to accept at least that request-body size. A smaller limit can return HTTP 413 while health checks pass. Other ingress controllers require their equivalent setting.
For an ingestion-only pilot, leave both
instructionHub.analysis.activationAtandinstructionHub.analysis.repository.urlempty. The chart then omits model and repository settings from the worker. Complete all analysis settings before enabling analysis. See the manual Helm reference for supported providers and value mappings. -
Render and install. Download the pinned public worker chart, then render it to catch missing required values without changing the cluster:
Terminal window helm pull oci://ghcr.io/promptless/charts/instruction-hub-worker \--version 0.3.0 --untarhelm lint ./instruction-hub-worker --values values.yamlhelm template instruction-hub-worker ./instruction-hub-worker \--namespace pig --values values.yaml > rendered-worker.yamlReview the image digest, ingress, service account, CA mount, and Secret references. The published chart supplies
image.digest; when rendering from a source checkout, set it to the verified worker digest from the matching release. Then install:Terminal window helm upgrade --install instruction-hub-worker ./instruction-hub-worker \--namespace pig \--values values.yaml \--atomic --wait --timeout 20mA pre-install or pre-upgrade Job applies database schema changes before the new worker starts. Both workloads use the existing
pig-analyzerServiceAccount in this example. A ServiceAccount created by the worker chart is unavailable to its pre-install hook, so keep the account under your platform or GitOps workflow.
Upgrade a manual installation
Section titled “Upgrade a manual installation”Review the target release’s database, storage, and schema requirements before each upgrade. Apply required infrastructure changes through your platform workflow and verify the recovery points for that exact release before a destructive migration. The manual chart does not enforce the supervisor’s confirmation ConfigMap.
Schedule a maintenance window, stop new analyzer traffic, and quiesce the existing analyzer before running helm upgrade. Confirm that its pods have stopped before the pre-upgrade migration Job starts. Helm runs this hook before updating the Deployment; the Deployment’s Recreate strategy alone does not prevent the old analyzer from accessing the database during migration. Coordinate this with GitOps reconciliation so it does not restart the old workload.
Install the pinned target chart with your reviewed values, then repeat the complete-session verification below. If migration fails, preserve the Job logs and inspect the schema before restarting the previous image. Follow the release’s recovery procedure; an application rollback does not reverse database changes.
Verify a complete session
Section titled “Verify a complete session”Follow Verify your deployment. Use deployment/instruction-hub-worker for analyzer log commands. The same enrollment, storage, analysis, and dashboard checks apply to this installation.
Troubleshooting
Section titled “Troubleshooting”| Symptom | Check and next action |
|---|---|
helm template reports a missing value | Fill in the required deployment settings and all model and repository settings when activationAt is set. |
| Migration fails | Read kubectl -n pig logs job/instruction-hub-worker-migrate. Check PostgreSQL reachability, TLS, schema permissions, and the migration service account. Successful hook Jobs are deleted automatically. |
| Pod cannot start | Inspect pod events for missing Secret keys or image-pull failures, then worker logs for configuration validation errors. |
| HTTPS fails | Check DNS, certificate coverage, IngressClass, and the route to Service port 8080. |
| Host checks in but traces do not arrive | Check collector status, capture policy, and host-to-worker upload access. Preserve the host’s local collection state. |
| Trace object remains pending or failed | Check workload identity, bucket or container permissions, encryption-key access, and trace_object_last_error. |
| Analysis never starts | Confirm activation time, a complete canonical trace, the quiet window, and repository/model configuration. |
| Analysis fails | Use analysis_run_id and error_category to investigate repository access, provider authentication, rate limits, and worker resources. |
Do not delete database rows, the trace-object prefix, or collection watermarks to clear a stalled deployment. Preserve the evidence, fix the failing dependency, and use the observability and recovery guidance.
Next steps
Section titled “Next steps”Review findings, configure observability, and record an upgrade owner. Each upgrade in this installation remains an operator-controlled release. Do not install a supervisor to manage the same workload without an ownership transfer.