Reconfigure a bundle in Next mode
Use bundle reconfigure to replace environment defaults without rebuilding package content.
What you’ll accomplish
Section titled “What you’ll accomplish”- Replace an artifact’s defaults.
- Create a derivative in a local directory or OCI registry.
- Keep the package content unchanged.
Prerequisites
Section titled “Prerequisites”- UDS CLI installed
- A local
.tar.zstbundle artifact or an OCI bundle reference - A
defaults.uds.hclfile containing the replacement variables - A matching bundle public key or keyless certificate constraints for the source artifact
- A signing key or keyless signing identity for a signed derivative
-
Create a defaults file
Create a replacement file such as
defaults.production.uds.hcl:defaults.production.uds.hcl variables = {cluster_name = "production"replica_count = 3enable_metrics = true}A
defaults.uds.hclfile supports only thevariablesattribute. Useconfig.uds.hclwith--configfor deploy-time options such as architecture or log level. -
Reconfigure a local artifact
Create an unsigned derivative for a local alpha workflow:
Terminal window mkdir -p ./distCLI_FEATURES=NextMode=true uds bundle reconfigure \./uds-bundle-my-app-amd64-1.0.0.tar.zst \--defaults ./defaults.production.uds.hcl \--suffix -production \--output-dir ./dist \--skip-signature-verification \--unsignedFor a signed derivative, omit the unsigned flags and provide a signing key or use keyless signing:
Terminal window CLI_FEATURES=NextMode=true uds bundle reconfigure \./uds-bundle-my-app-amd64-1.0.0.tar.zst \--defaults ./defaults.production.uds.hcl \--suffix -production \--public-key ./cosign.pub \--signing-key ./cosign.key \--output-dir ./distThe local output defaults to the current directory.
--output-dirlets you choose another directory. -
Reconfigure an OCI artifact
Use an OCI source to publish a derivative tag. OCI sources do not support
--output-dir:Terminal window CLI_FEATURES=NextMode=true uds bundle reconfigure \oci://registry.example.com/my-org/my-app:1.0.0 \--defaults ./defaults.production.uds.hcl \--suffix -production \--public-key ./cosign.pub \--signing-key ./cosign.keyReconfigure verifies the source bundle signature by default. Use
--skip-signature-verificationonly for a locally controlled unsigned alpha source. Do not use it to bypass verification for registry-backed artifacts. Sign the new artifact, or use--unsignedfor local alpha work.
Verification
Section titled “Verification”If you created a signed derivative, inspect it and verify its bundle signature:
CLI_FEATURES=NextMode=true uds bundle inspect ./dist/uds-bundle-my-app-production-amd64-1.0.0.tar.zstCLI_FEATURES=NextMode=true uds bundle verify \ ./dist/uds-bundle-my-app-production-amd64-1.0.0.tar.zst \ --public-key ./cosign.pubIf you created an unsigned local alpha derivative, inspect it without running bundle verify. It has no bundle signature, so its integrity and origin are not established.
CLI_FEATURES=NextMode=true uds bundle inspect ./dist/uds-bundle-my-app-production-amd64-1.0.0.tar.zstThe output filename includes the configured suffix. Use the path printed by bundle reconfigure when the architecture or version differs.
Troubleshooting
Section titled “Troubleshooting”Problem: The command rejects the defaults file
Section titled “Problem: The command rejects the defaults file”Symptom: The command reports an unsupported block or attribute in the replacement defaults file.
Solution: Keep the file to a variables attribute. Put deploy-time options in config.uds.hcl and pass it with --config during deployment.
Related documentation
Section titled “Related documentation”- Create a bundle in Next mode - Create the source bundle artifact.
- Publish and pull a bundle in Next mode - Publish and retrieve OCI artifacts.
- Next mode reference - Review defaults, configuration, and artifact behavior.