-
-
Notifications
You must be signed in to change notification settings - Fork 449
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
PROPOSAL: Improve Contributor Tooling #146
Comments
For the dev testing subsystem, I'm working on a comprehensive docker tooling. I'm just waiting for the new volume driver moby/moby#14242 to be released so to be able to handle file sync to the docker host elegantly AND completely platform independent. |
Most of this if subject to personal preference. Docker is a matter of preference. |
You're absolutely right, it is very important to follow the maxime "default but swapable". The long term benfit of this kind of tooling/best practice flourishes slowly with the ones that do not have a personal preference, yet. Preparing a wiki stub page, right now. |
guys, about that, at Akretion we are using Voodoo a tool for that: https://github.com/akretion/voodoo feel free to contribute to the project. We were in a kind of a big rush during 2015, so we didn't communicate about the project yet but we are using it since 6 months in many projects, so far so good. So if your are interested you can test and contribute. But please don't make public statements about it yet as we plan to adjust a few things and then make some big presentation of it. Voodoo is opinionated and built around the Anybox buildout recipe. Regards. |
@rvalyi that's very interesting, I wasn't aware of this. I'll have a deeper look, for now: Be aware, that docker-compose doesn't ship windows binaries yet. |
Update: It's VERY interesting! 😄 What's your solution for syncing local files to the docker volumes? Mind the new release of |
so if for instance some project will create a bash script doing the OCA lint tests (like Travis), then this should be a standalone script and Voodoo will use it (it shouldn't be done inside Voodoo). Also because t extends Docker Compose, Voodoo is very easy to extend with plugins (like Eclipse dev mode plugin etc...). @blaggacao IMHO the light mode is just to take a Voodoo repo and run it as a standard buildout project with virtualenv and without Docker. Now, once you want to avoid cluttering the dev machine with the python and native deps, it means virtualization and here I believe the default Voodoo Docker usage is the lightest thing you can imagine, Now as I said voodoo could ship a more generic lint script. It can embedded the Acsone Eclipse debug buildout recipe... So we see that kind of modularization. About windows: either Docker compose get mature for Windows (Microsoft is investing on that right and eventually we clean the Voodoo python launcher a bit), either we ship a Vagrant of the thing with a degraded Vagrand Launcher but that would still do 80 of what user need (the smart is inside the portable Dockerized Linux image anyway). Voodoo is also a way to tell our customers: look; you can easly get a local replica of your Cloud instance: so no stress we are really doing open source... |
@blaggacao @dreispt we also plan to fit Voodoo with OCA specific commands like: add an OCA repo X to my project, like a single command to fork and OCA repo or checkout a fresh pull request etc... |
In spite of vagrant: docker-machine. It's maturing, also on windows. |
FYI we are working with a runbot based on docker Feel free of use and comment. 2015-10-16 11:25 GMT-05:00 David Arnold notifications@github.com:
Moisés López Calderón |
@moylop260 👍 Thanks! @rvalyi @moylop260 I'm very in favor of docker in general, because of it's portability. For real platform independence, we need a virtualization layer for it to work. To be as agile as possible, I'm in favor of bindmounting the source files directly into the docker via the new What's your opinion about this strategy, coming from the background of your respective tools? |
@blaggacao yes we do sync local files with what the Docker server uses, it's inherited from Devstep (Voodoo is based on Docker Compose, Devstep and Anybox recipe basically). @moylop260 great! all that will converge, eager to test it and kudos for all the runbot work. |
@rvalyi For understanding: Do you sync with the docker host, or the docker directly? |
@blaggacao Voodoo and Devstep makes it the simplest you can imagine; you just fucking cd to the fucking host git project. Do voodoo run and then ak run and it's running. If you change a file with your IDE, then just do CTRL+C and ak run again (the Odoo dev mode will do it too). the project directory is a shared volume (-v option) shared with /workspace in your Docker container (read about Devstep to understand http://fgrehm.viewdocs.io/devstep/ ) Note: the guy behind Devstep isn't exactly a beginner, it's him who did the Vagrant LXC plugin for years for instance... |
OK nice, and I assume it's platform independent? |
@blaggacao I believe Devstep only works on Ubuntu. As for Voodoo, provided we do some Vagrant fall back launcher we can easily have a degraded mode on Windows and MacOS. |
@moylop260 @moylop260 I'd like to discuss the pros and cons semi-publickly in a chat room, as it seems by now, we are doomed to IRC. Can I join there without tooling? Are you there at some time of today's wonderful day? |
I confirm voodoo is a really efficient dev environnement. |
I yesterday had the chance to test @moylop260 solution.
What it does is, it transforms the defintions of the travis.yaml into a buildable dockerfile and adds a build and run script which does ease the job for the unexperienced. It fetches all contents from remote or local (!) repos, so it is proxied by the git subsystem. This ensures an aligned workflow. Finally, it syncs source files via sftp or similar protocol, but this is likely to change with the advent of Anyone, can give insight about the pros and technical details of voodoo to get this discussion to the next level? Thx. |
Another question, how do we get compiled binaries for this tool? |
Just my 2 cents:
|
Thank you for your input! I think editorconfig is quite a good idea, too. It seems they enlarged support for editors by now. The problem to spin up instance does unfortunatley not stop with a single docker image. Many repositories need a special environment either OS or python, which needs to be handled. But the bigger problem right now is that it doesn't work smoothly on windows because of the way the code is mounted to the docker in windows (via a hypervisor). Your idea to include wdb is VERY intersting, I suppose the reason for it is to avoide the interactive shell problem, that might occure across guest-host connections? |
I take this as a vote for .editorconfig 👍 😄 |
You need 1 PR per repo, adding a I recommend you to do the first PR to https://github.com/OCA/maintainer-tools/ and let OCA review the file, and when merged just copy + paste + PR the same file to each other repo. About the Docker volumes + Windows problem, just drop Windows 😉. Another much harder option would be to share a folder from windows and add samba to the server, mounting sources from there in the VM. Even better, you can add the samba stuff in another image and link it to the stack. And about wdb, that's a problem that it solves, but it's also about wdb being the most awesome debugger in history. |
@yajo Thank's for your inputs! That's the spirit, the problem about dropping windows is, that it is not sustainable because with their new strategy, they are the only "deviceless os" on the market. I bet the gain market share. Obviously programmers love linux, but odoo is not so hard to understand for non programmers, so that we would need to exclude them... Actually, I think samba with the new docker volume driver is the adequate solution... For now, there are rough edges around the virtualization layer (hyper-v, virtualbox), not so much the sharing, this is quite feasible... If there is an option for nfs on windows, we could even reuse an existing volume driver https://github.com/SvenDowideit/docker-volumes-nfs But this guy is also very into samba, and for sure will come up with something during the next months... |
Let's see: SvenDowideit/docker-volumes-nfs#5 |
@yajo do you know go programming? |
I never used Go, sorry. If we want an easy, stable and reproducible environment for everyone, Docker is probably the best chance. Although obviously there is no native version for Windows yet, it is officially supported through VirtualBox. Also this might be interesting for Windows users: moby/moby#7052 (comment) Now opinions:Voodoo adds little to docker-compose except for some syntactic sugar. docker-compose now supports inheritance of .yml files, so an environment with some of these preconfigured to launch different scripts in the image and just switching it. Examples:
So mostly voodoo adds alias, which is something quite personal to each developer IMHO; and anyway if you want to standarize those, just add I'd prefer to stick with docker-compose since it's a common tool to all Docker community and it eases the learning curve for those knowing it (or at least reuses it for those coming directly from Odoo). Also it's compatible with voodoo for those wanting it as an alternative manager. In any case, I don't think implementing Voodoo in Go is a good idea. docker-compose itself is made in Python, and Odoo too, so all OCA developers are more comfortable with that language. I see no need for rewriting. FootnoteIMHO it's much better to do that with variables. Imagine this
The developer comments out what he does not want, runs Another idea is to do it by scripts, as you saw I have in my stack, but maybe this is easier for sharing with a community. |
I'm basically very much on the edge of 7052, so this is atm my main concern, but I have same clues... 💃 I'm dreaming of a
|
CC @rafaelbn |
Fixed with the following script https://github.com/OCA/maintainer-quality-tools/blob/master/git/pre-commit |
This evolves from and closes #145.
I claim, there is a benefit on incentive to converge contributor tooling, as odoo community, for the nature of the product, is characterized by many half-programmers. For the sake of efficient discussion, if you want to challenge this claim, please mark this specifically in your comment.
A generally adoptable tooling should be:
It comprises the following subsystems:
Optimization candiates per Subsystem:
Editor / IDE:
git subsystem:
dev testing subsystem:
The text was updated successfully, but these errors were encountered: