This is an extension for VS Code. This extension enables interactive debugging of Dockerfile.
This extension depends on buildg, an interactive debugger for Dockerfile. You need to install buildg >= v0.4.0 on your system to use this extension.
- Breakpoints and step execution
- Inspecting steps
- Interactive shell on a step with your own debugigng tools
- Rootless execution
Usage of debugger UI is documented in the VS Code documentation: https://code.visualstudio.com/docs/editor/debugging
Refer to buildg repo for detailed usage of buildg (REPL, configuration, known limitations, etc.): https://github.com/ktock/buildg/tree/main/examples/dap
- Requirements
- buildg >= v0.4.0 needs to be installed on the host.
Released VSIX files are available from https://github.com/ktock/vscode-buildg/releases
After you download a VSIX file, install it to VS Code as the following.
code --install-extension buildg-${VERSION}.vsix
This extension isn't available on Visual Stdio Marketplace as of now. We will distribute it there in the future.
You can configure buildg through launch.json.
The following propertiess are provided.
programstring REQUIRED : Absolute path to Dockerfile.stopOnEntryboolean : Automatically stop after launch. (default:true)targetstring : Target build stage to build.imagestring : Image to use for debugging stage.build-argsarray : Build-time variables.ssharray : Allow forwarding SSH agent to the build. Format:default|<id>[=<socket>|<key>[,<key>]]secretsarray : Expose secret value to the build. Format:id=secretname,src=filepath
Common and mandatory properties are the following (see VS Code documentation for details).
type: Type of debugger to use. Must bedockerfile.request: The request type.launchis only supported in buildg as of now.name: The reader-friendly name of this configuration.
Example launch.json is available at ./sampleWorkspace/.vscode/launch.json
- Issue tracker of vscode-buildg: https://github.com/ktock/vscode-buildg/issues
- Issue tracker of buidg: https://github.com/ktock/buildg/issues
Initial release
Run on buildg v0.4.0
NOTE: buildg >= v0.4.0 is required since this release.
