dcloud deploy hosting create-bundle

Start a deployment of a pooled app from a build: returns an upload URL for the bundle

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

The bundle is a tar.gz of .next/standalone, .next/static, .next/server, .next/ews-outputs.json and public/ (the starter template workflow makes it). PUT it to uploadUrl within an hour, then call complete-bundle. A commit on the app branch (default main) becomes production; any other branch a preview at its own URL.

Synopsis

dcloud deploy hosting create-bundle id --commit-sha commitSha --sha256 sha256 --size-bytes sizeBytes [flags]

Arguments

  • <id>Required

    string

    Also accepted as --id. Constraints: uuid

Flags

  • --commit-shaRequired

    string

    The commit the bundle was built from; also names its preview URL

    Constraints: 4-64 chars, /^[0-9A-Za-z._-]+$/

  • --branchOptional

    string

    The branch the commit was pushed to: the app’s branch (default main) makes it production, any other a preview; omitted or null counts as production

    Constraints: 1-255 chars

    May be null.

  • --sha256Required

    string

    SHA-256 of the tar.gz, in hex; checked again after download

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

  • --size-bytesRequired

    number

    Exact size of the tar.gz in bytes; completing fails if the upload differs

    Constraints: integer, 1-1073741824

Example

dcloud deploy hosting create-bundle id --commit-sha example --sha256 example --size-bytes 1

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