Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Dev Containers config #2255

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open

Add Dev Containers config #2255

wants to merge 6 commits into from

Conversation

astrojuanlu
Copy link
Member

@astrojuanlu astrojuanlu commented Jan 30, 2025

Description

Why was this PR created?

Gitpod has been up until now the preferred way to do QA of PRs without having to build a full development environment.

However, Gitpod Classic is going away, and we need to find another solution.

Gitpod Flex works with Dev Containers https://www.gitpod.io/blog/introducing-gitpod-flex#development-container-support so here is my first attempt to add Dev Containers config.

Development notes

This mostly works. But almost by chance...

The backend command is succeeding. And somehow it's launching both the backend and the frontend? I don't fully understand why ❓

I didn't see a npm install step anywhere listed in our CONTRIBUTING.md (hitting #1764 again?) but I added to the dev container anyway, and looks like it's working.

When I tried to configure the image to use NodeJS 18 though, I found some inconsistencies between what the IDE tells me and what the standards say.

image

I would like somebody else to pick this up if it's not too much to ask 🙏🏼

QA notes

https://code.visualstudio.com/docs/devcontainers/create-dev-container

Run the >dev containers: rebuild and reopen command and check that everything works.

Checklist

  • Read the contributing guidelines
  • Opened this PR as a 'Draft Pull Request' if it is work-in-progress
  • Updated the documentation to reflect the code changes
  • Added new entries to the RELEASE.md file
  • Added tests to cover my changes

@astrojuanlu
Copy link
Member Author

The node-gyp problem took care of itself.

Signed-off-by: Juan Luis Cano Rodríguez <[email protected]>
Signed-off-by: Juan Luis Cano Rodríguez <[email protected]>
Signed-off-by: Juan Luis Cano Rodríguez <[email protected]>
Signed-off-by: Juan Luis Cano Rodríguez <[email protected]>
Signed-off-by: Juan Luis Cano Rodríguez <[email protected]>
Signed-off-by: Juan Luis Cano Rodríguez <[email protected]>
@astrojuanlu
Copy link
Member Author

Aside from my comments above, the Dev Container works. So this is ready for review & merge.

"onCreateCommand": "./.devcontainer/onCreateCommand.sh",

"postStartCommand": {
"backend": "nohup bash -c 'uv run python package/kedro_viz/server.py demo-project &' > backend.out 2> backend.err < /dev/null",
Copy link
Contributor

Choose a reason for hiding this comment

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

I am a little confused why this happens, from where does it get the build files?

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.

2 participants