save the planet 1/2: don't copy odoo/src in every dev images, it's already mounted! #91
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR improves the developer experience in the dev mode of Docky
back in the early Docky versions we were doing it right and more recently somebody screwed it. Basically /odoo/src will already be a mounted volume when running Docky (docky run) so Odoo source code will be be available as expected.
The only thing we need in the build phase of the Dockerfile is just enough of Odoo metadata to get the next pip install lines to run:
And this is exactly the just enough files I copied in the 5 lines before in this PR!
You can test with
docky build
it locally. In the best case before you were copying around 250 Mb of Odoo files if you were a git-autoshare ninja and had just an odoo shallow clone in your odoo/src. But I guess many of us, in fact had full blown odoo clones in odoo/src (because otherwise without git-autoshare you cannot merge a damn Odoo pull request). That is people had around 5.7 Gb of useless odoo git files in every project they were working on locally. 6 or 7 active projects you you easily kill an SSD for nothing!cc @sebastienbeau @PierrickBrun @hparfr @bealdav @renatonlima @mbcosta