Foundation-only installer for Cortex Foundation master infrastructure. Do not run this for validators or third-party operators.
This guide covers the committed Kubernetes installer for the master control plane. It installs the Platform master admin API, proxy, broker, shared master ConfigMap, and a full Helm auto-upgrade CronJob in the master namespace. It does not install validator workloads, chain submission jobs, or any key material.
PLATFORM_NAMESPACE=platform-master
Use a different namespace only for Cortex Foundation managed test clusters. Do not reuse the namespace reserved for normal operator installs.
Run from the repository root:
./scripts/install-master.sh --database-url postgresql+asyncpg://platform:<password>@postgres.platform.svc.cluster.local/platformThe script performs these actions:
- Prints the foundation-only warning before it changes the cluster.
- Applies Namespace, ServiceAccount/RBAC, ConfigMap, admin Deployment and Service, proxy Deployment and Service, broker Deployment and Service, and
platform-master-helm-upgraderwithout deleting healthy existing workloads. - Stores the required database URL in
secret/platform-master-database-urland references it from Deployments. - Runs the master admin API with
platform master run --config config/master.kubernetes.yaml. - Runs the proxy and broker with the same master config.
Useful options:
export PLATFORM_DATABASE_URL='postgresql+asyncpg://platform:<password>@postgres.platform.svc.cluster.local/platform'
./scripts/install-master.sh --namespace platform-master
./scripts/install-master.sh --image ghcr.io/platformnetwork/platform-master:v1.2.3@sha256:<digest>
./scripts/install-master.sh --auto-upgrade-schedule '*/5 * * * *'
./scripts/install-master.sh --auto-upgrade-helm-image alpine/helm:3.15.4
./scripts/install-master.sh --auto-upgrade-repo PlatformNetwork/platform --auto-upgrade-ref main
./scripts/install-master.sh --netuid 0
./scripts/install-master.sh --cleanupCleanup is scoped to installer-managed master objects and removes secret/platform-master-database-url. It does not delete unrelated workloads or namespaces.
The installer creates cronjob/platform-master-helm-upgrader. The job uses a namespace-local ServiceAccount with ConfigMap-backed Helm release storage and runs a full Helm upgrade from GitHub:
helm upgrade --install platform-master ... --atomic --wait --cleanup-on-fail
The upgrader downloads the configured repo/ref, reads the chart under deploy/helm/platform, and applies master-only values in the master namespace. It sets HELM_DRIVER=configmap, uses concurrencyPolicy: Forbid, and does not read or print Kubernetes Secret values. The master database URL must be supplied by the existing Secret referenced by the chart values. The installer pins only live-safe non-secret references for future self-upgrades, including database.urlSecret.name=platform-master-database-url, database.urlSecret.key=url, security.existingSecret=platform-secrets, kubernetes.namespace, and kubernetes.serviceAccount; never place database URLs, tokens, or other secret values in autoUpgrade.extraSet.
Before relying on self-upgrades, verify the referenced Secret and keys exist without printing their values:
kubectl -n platform-master get secret platform-master-database-url -o jsonpath='{.data.url}' >/dev/null
kubectl -n platform-master get secret platform-secrets -o jsonpath='{.data.admin_token}' >/dev/null
kubectl -n platform-master get cronjob platform-master-helm-upgraderIf any prerequisite is missing, keep the Helm-upgrader CronJob suspended with autoUpgrade.suspend=true until the referenced Secret exists with the intended key. If the deployment is already healthy, use these checks to confirm the CronJob bootstrap references instead of replacing the deployment just to recreate the CronJob.
- It does not create validator resources.
- It does not run the master weights CLI command.
- It does not create a master on-chain submission CronJob.
- It does not ask for, print, or store key material.
- It does not use external paste services as the canonical source.
kubectl -n platform-master get deployment platform-master-admin platform-master-proxy platform-master-broker
kubectl -n platform-master get cronjob platform-master-helm-upgrader
kubectl -n platform-master logs -f deployment/platform-master-adminBefore changing the installer or docs, run:
bash -n scripts/install-master.sh
uv run pytest tests/unit/test_master_install_docs.py tests/unit/test_validator_install_docs.py -qRun the full installer only when the current Kubernetes context and namespace are owned by Cortex Foundation master infrastructure.