appendDockerfileInstructions expects an array of strings with each string containing a Dockerfile instruction, e.g.
This option is very useful to add development-specific instructions (installing dev tooling like debuggers, setting a different runtime user for the container etc.) without the need to change the actual Dockerfile.
DevSpace adds these instructions dynamically to your Dockerfile when building images. However, this happens in-memory and does not change the Dockerfile.
Combination with Profiles
It is often useful to create a profile
production with a patch that removes the
appendDockerfileInstructions entirely. This way, you can also evaluate what you are working on in a more production-like way using a single command:
devspace deploy -p production