DEV Community

Lynn Langit
Lynn Langit

Posted on

Containers for GitHub Codespaces

Tried out using custom containers as a basis for GitHub Codespaces using the Java example from Microsoft - list.

Create and populate a .devcontainers folder at my Repo root with (modified) example DOCKERFILE, devcontainer.json and supporting script files and away we go.

Custom Codespace being created
Alt Text

Using the Java Codespace (includes Maven & Gradle by default)
Alt Text

The supporting .devcontainers.json file
Alt Text

Easy-peasy. Also learned that if I don't own the repo on which I am creating a custom Codespace, then when initially creating a Codespace Github will automatically create a repo fork.

Top comments (0)