feat: add GitHub Codespaces dev container#1807
Conversation
Adds .devcontainer/ configuration so new contributors can spin up a fully-configured AntAlmanac dev environment in Codespaces. The post-create script installs pnpm dependencies, seeds .env files from the provided examples, starts the local Postgres via docker compose, runs migrations, and fetches the static course data.
There was a problem hiding this comment.
1 issue found across 3 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
The readiness loop previously broke only on success, so a database that never came up would silently fall through to db:migrate and emit a confusing migration error. Track the ready state explicitly, print actionable recovery steps, and exit before the dependent steps run when the wait times out. Co-authored-by: Dominic Seung <dominic@seung.dev>
calebwongg
left a comment
There was a problem hiding this comment.
not the most versed in shell script but everything looks good to me after we delete the tailwind extension. lowkey my codespaces takes like 10 minutes to start up but it should be just because codespaces itself is heavy. hopefully this motivates more open source contributers🤞🤞
AntAlmanac doesn't use Tailwind (MUI only); the lone match was a comment in Theme.tsx referencing Tailwind's breakpoint scale.
In my testing, most of the startup time is spent waiting for The dev container can also be used locally as long as you have Docker installed if GitHub codespaces doesn't offer enough performance. If #1848 is merged, it might be able to speed up codespace creation. |
There was a problem hiding this comment.
It just occurred to me that users are still going to have to generate their own aapi key and their own better auth secret. So they still will have to do slight config for their environment, which I suppose takes away a little from the point of codespaces. I guess theres nothing we can really do about it because we don't want to globalize a key. Aside from that though codespaces does resolve other onboarding conflicts. So lgtm
Summary
Create an easy way to use Github Codespaces, which will make it easier for new developers to start working on AntAlmanac (and fix any machine-specific environment problems).
Test Plan
pnpm devin the terminal.