kusion compile
Compile Kusion models to the Spec (intent)
Synopsis
Compile Kusion models in a Stack to the Spec (intent)
The command must be executed in a Stack or specifying a Stack dir with the -w flag. You can specify a list of arguments to replace the placeholders defined in KCL, and output the compiled results to a file when using --output flag.
kusion compile [flags]
Examples
# Compile main.k with arguments
kusion compile -D name=test -D age=18
# Compile main.k with arguments from settings.yaml
kusion compile -Y settings.yaml
# Compile main.k with work directory
kusion compile -w appops/demo/dev
# Compile with override
kusion compile -O __main__:appConfiguration.image=nginx:latest -a
# Compile main.k and write result into output.yaml
kusion compile -o output.yaml
# Compile without output style and color
kusion compile --no-style=true
Options
-D, --argument stringToString Specify the top-level argument (default [])
-n, --disable-none Disable dumping None values
-h, --help help for compile
--no-style Disable the output style and color
-o, --output string Specify the output file
-a, --override-AST Specify the override option
-O, --overrides strings Specify the configuration override path and value
-Y, --setting strings Specify the command line setting files
-w, --workdir string Specify the work directory
SEE ALSO
- kusion - Kusion is the platform engineering engine of KusionStack