Skip to content

Add a basic Devcontainer#3291

Open
blue42u wants to merge 3 commits intospack:developfrom
blue42u:devcontainer
Open

Add a basic Devcontainer#3291
blue42u wants to merge 3 commits intospack:developfrom
blue42u:devcontainer

Conversation

@blue42u
Copy link
Copy Markdown
Contributor

@blue42u blue42u commented Feb 6, 2026

Development containers ("Devcontainers") are a way to describe a reproducible and automatically generated development environment, based off a Docker or Podman container. These allow new (and current) developers and contributors start writing and testing code faster and reduce the barrier for entry.

Devcontainers is still largely a VSCode feature, but is slowly gaining traction among IDEs (IntelliJ, Zed) and cloud-hosted development (GitHub Codespaces, Ona). In addition, Devcontainers is the development model supported by "atomic" Linux distros such Project Bluefin (part of Universal Blue).

This PR adds a boilerplate devcontainer spec based on the spack/ubuntu-noble:develop container image. The container is configured with a persistent volume for Spack installs, staging area in the container's /var/tmp (to avoid size issues if /tmp is a tmpfs), and builds for the generic architecture by default.

Signed-off-by: Jonathon Anderson <anderson.jonathonm@gmail.com>
@haampie haampie requested a review from wdconinc February 7, 2026 09:48
@wdconinc
Copy link
Copy Markdown
Contributor

wdconinc commented Feb 9, 2026

I'd review this in codespace but apparently I can't "for my own protection" since it's on a fork. Have you checked that codespaces handles this well?

@blue42u
Copy link
Copy Markdown
Contributor Author

blue42u commented Feb 9, 2026

Ah, security.

I hadn't checked Codespaces specifically until just now, it worked fine except spack wasn't sourced properly because Codespaces doesn't use a login shell for the integrated terminal. It works fine on local VSCode, just not in Codespaces. Weird.

I've thrown in a quick patch to source setup-env.sh in non-login shells. With that, Codespaces seems fully functional:

image

Copy link
Copy Markdown
Contributor

@wdconinc wdconinc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for verifying this works in codespaces.

@alalazo alalazo self-assigned this Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants