name option is mandatory and expects a string defining the name of the profile.
replace option expects an object with the following (optional) fields:
imageswhich will replace the entire
imagessection of the devspace.yaml
deploymentswhich will replace the entire
deploymentssection of the devspace.yaml
devwhich will replace the entire
devsection of the devspace.yaml
dependencieswhich will replace the entire
dependenciessection of the devspace.yaml
hookswhich will replace the entire
hookssection of the devspace.yaml
Example: Using Config Replace For Profile
- The above example defines 1 profile:
- When using the profile
production, the config section
imageswould be entirely replaced and additionally, 1 patch would be applied.
- The resulting config used in-memory when the profile
productionis used would look like this:
Combine Replace & Patches
As shown in this example, it is possible to use
patch options in combination.
devspace print -p [profile]
The following command is useful to verify that the profile modifies the config as intended:
The above command would print the config after applying all profile
replace statements as well as after replacing all config variables.