dcloud deploy cache bind

Bind a managed Valkey cache (its private address, in the app’s VPC)

IAM deploy:ManageCacheBindingChanges stateAsks before it deletes (-y skips)

Generates {prefix}REDIS_URL and {prefix}VALKEY_URL (redis://default:<password>@<private address>:6379) at every rollout. Refused unless every machine of the app is in the cache’s VPC. Saving does not restart the app. Pass redeploy: true to roll the live deployment’s own source onto the new configuration (also needs deploy:DeployApp); otherwise the response and GET …/env report pending until someone redeploys.

Synopsis

dcloud deploy cache bind id --cache-cluster-id cacheClusterId [flags]

Arguments

  • <id>Required

    string

    Also accepted as --id. Constraints: uuid

Flags

  • --cache-cluster-idRequired

    string

    The managed Valkey cache to bind

    Constraints: /^ewc-[0-9a-f]{12}$/

  • --env-prefixOptional

    string

    Put in front of every generated variable name (e.g. CACHE_ gives CACHE_REDIS_URL), so one app can hold several bindings of a kind; default empty

    Constraints: max 32 chars, /^([A-Z][A-Z0-9_]*_)?$/

  • --redeployOptional

    boolean (--redeploy / --no-redeploy)

    Also roll the live deployment onto the new configuration; default false

Example

dcloud deploy cache bind id --cache-cluster-id example

Generated from the API description, the same one the API checks requests against and the CLI is built from.