Skip to main content
Version: v0.9

kusion apply

Apply the operation intents of various resources to multiple runtimes

Synopsis

Apply a series of resource changes within the stack.

Create or update or delete resources according to the KCL files within a stack. By default, Kusion will generate an execution plan and present it for your approval before taking any action.

You can check the plan details and then decide if the actions should be taken or aborted.

kusion apply [flags]

Examples

  # Apply with specifying work directory
kusion apply -w /path/to/workdir

# Apply with specifying arguments
kusion apply -D name=test -D age=18

# Apply with specifying setting file
kusion apply -Y settings.yaml

# Apply with specifying spec file
kusion apply --spec-file spec.yaml

# Skip interactive approval of plan details before applying
kusion apply --yes

# Apply without output style and color
kusion apply --no-style=true

Options

  -a, --all --detail              Automatically show all plan details, combined use with flag --detail
-D, --argument stringToString Specify the top-level argument (default [])
-C, --backend-config strings backend-config config state storage backend
--backend-type string backend-type specify state storage backend
-d, --detail Automatically show plan details with interactive options
--dry-run Preview the execution effect (always successful) without actually applying the changes
-h, --help help for apply
--ignore-fields strings Ignore differences of target fields
--no-style no-style sets to RawOutput mode and disables all of styling
--operator string Specify the operator
-o, --output string Specify the output format
-O, --overrides strings Specify the configuration override path and value
-Y, --setting strings Specify the command line setting files
--spec-file string Specify the spec file path as input, and the spec file must be located in the working directory or its subdirectories
--watch After creating/updating/deleting the requested object, watch for changes
-w, --workdir string Specify the work directory
-y, --yes Automatically approve and perform the update after previewing it

SEE ALSO

  • kusion - Kusion is the platform engineering engine of KusionStack
Auto generated by spf13/cobra on 28-Sep-2023