|
1 | 1 |  |
2 | 2 |
|
3 | | -# Container Runtime Debugging Support |
| 3 | +# Container Runtime Debugging Support (aka Duct Tape) |
4 | 4 |
|
5 | | -In development |
| 5 | +_Caution: this is work-in-progress_ |
| 6 | + |
| 7 | +This repository gathers additional dependencies required to debug |
| 8 | +particular language runtimes with [`skaffold debug`](https://skaffold.dev/docs/how-tos/debug/). |
| 9 | +These dependencies are packaged as a set of container images suitable |
| 10 | +for use as `initContainer`s on a pod. When executed, a container image |
| 11 | +copies these dependencies to `/dbg/<runtimeId>`. |
| 12 | + |
| 13 | +The idea is that `skaffold debug` will transform k8s manifests to |
| 14 | +make available any support files required to debug specific language |
| 15 | +runtimes. For example, a Kubernetes podspec would be transformed to |
| 16 | + |
| 17 | + - mount a volume on `/dbg` to hold the debugging support files |
| 18 | + - run one or more of these `initContainer`s to populate the volume |
| 19 | + - mount the volume on the applicable containers as `/dbg` |
| 20 | + |
| 21 | +Current language runtimes: |
| 22 | + * `go`: provides [Delve](https://github.com/go-delve/delve) |
| 23 | + * `python`: provides [`ptvsd`](https://github.com/Microsoft/ptvsd), |
| 24 | + a debug adapter that can be used for VS Code and more, for |
| 25 | + Python 2.7 and 3.7 |
| 26 | + * `netcore`: provides `vsdbg` for .NET Core |
| 27 | + |
| 28 | +## Development |
| 29 | + |
| 30 | +This directory includes a `skaffold.yaml` for development of the |
| 31 | +these `duct-tape` initContainer images. Each image is expected to |
| 32 | +be standalone and not require downloading content across the network. |
| 33 | +To add support for a new language runtime, an image definition |
| 34 | +should download the necessary files into the container image. The |
| 35 | +image's entrypoint should then copy those files into place at |
| 36 | +`/dbg/<runtime>`. The image should be added to the `skaffold.yaml` |
| 37 | +and referenced within `test/k8s-test-installation.yaml`. |
0 commit comments