feat(dev): add devcontainer config, add instructions to README#16677
feat(dev): add devcontainer config, add instructions to README#16677andig merged 2 commits intoevcc-io:masterfrom tfenster:master
Conversation
|
What's the difference to #15301? |
|
@andig Sorry, I didn't see that one. Going through that conversation, it looks to me like you didn't succeed in setting it up, so I created a quick video what the result looks like. I go from only VS Code and Docker Desktop installed on a Windows machine within 3 minutes to running evcc: If you want, I'd be happy to give you access to a Windows VM in the Cloud so that you can try for yourself. This configuration would even open up the possibility of Github Codespaces. Again, to give you an idea, I created the following video. Here I cheated a bit, because I went through the initial setup steps and If you don't see the benefits or don't want to have it in the main repo, I would offer to maintain a fork on my Github account that you could link to, stating that you don't support it and I would do support on a best-effort basis. I would very much prefer to have it in your repo as I really think it would lower the barrier for contributions, but that of course is your decision |
|
Additional comment as that was a concern in the other PR as well: |
|
And a last one: I would of course also look at issues with devcontainers if support is merged into the main repo. But also just on a best effort basis. I already do some open source work and am active in a few communities, so I have some experience, but time is limited, to be honest |
|
Tried to rebuild it: Any idea what that it? And (after restart): |
|
I guess the first problem breaks it. Are you running on Linux? Never saw this before. I found this https://www.kenmuse.com/blog/avoiding-dubious-ownership-in-dev-containers/ as potential solution |
|
Running on Mac |
|
@lippertmarkus would you have any idea why this breaks on a Mac? |
|
Seems to be related with the volume mount of the source code (unusual ownership & file modes). I have the same issue when opening the locally cloned repository in a devcontainer. However, when using "Clone in volume" for the devcontainer instead it works for me (M1 Mac). |
|
Ah, good pointer. @andig, did you use "clone in volume" or did you try the "open folder in container" option? |
|
Open Folder. I did not get clone to work. It ends in a different error that I cannot copy out since its overlaid by a dialog box. That said: I don't have the need and do not personally care. Feels like building giga-byte Docker images takes longer than just installing the little tooling we need, at least if not running on Windows. |
|
Great, thanks. I won't follow all issues here, but if anything comes up related to devcontainers, please let me know |
|
Very weird and as I can't repro, I struggle a bit. I'll try to find someone with a Mac... |
|
Also can't repro on my Mac |



Similar to evcc-io/app#17, to have an easier and cleaner way to set up a development environment, I added a devcontainer configuration and described in the README how it works. I tested building and running evcc in the container, which works fine.
Please let me know if you want any adjustments. Also, if you disagree with the approach, I can just keep my fork and would of course accept that
Thanks for your work!