Page MenuHomeSoftware Heritage

docker-dev: Make the docker-compose actually composable!
ClosedPublic

Authored by douardda on Dec 13 2018, 3:07 PM.

Details

Summary
  • move every docker build material in a per-container dedicated directory
  • use entrypoint.sh files as entrypoints
  • simplify a lot the Dockerfile: we only pip install what's necessary, the possibility of using swh packages from sources is done by detecting and installing every repo found in /src/swh-*. It's the responsibility of the user to mount local source directories via docker volumes.
  • rewrite the docker-compose file accordingly, using env vars when needed.

Related T1443

Diff Detail

Repository
rCDFD Dockerfiles for developers
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

When is the "init" "target" of dockerfiles/swh-storage/entrypoint.sh called?

If it's not automatic, it should be documented in the README.

dockerfiles/swh-storage/Dockerfile
12

this comment should be removed

ardumont added inline comments.
dockerfiles/swh-objstorage/Dockerfile
7

Duplicated steps.

There are some typos and all but i'm fine with fixing it myself.

Thanks!

This revision is now accepted and ready to land.Dec 13 2018, 3:13 PM

Also, the makefile could either go away or be refactored to use docker-compose build all over the place ;)

Also, the makefile could either go away or be refactored to use docker-compose build all over the place ;)

I like makefile so i'm for 2 ;)

When is the "init" "target" of dockerfiles/swh-storage/entrypoint.sh called?

If it's not automatic, it should be documented in the README.

Agreed, will do

fix typos and more doc in the readme

ardumont added inline comments.
README.md
66

*just*

This revision was automatically updated to reflect the committed changes.
dockerfiles/swh-objstorage/Dockerfile
3

We missed the RUN ;)

D812

ardumont retitled this revision from refactor a bit to docker-dev: Make the docker-compose actually composable!.Dec 13 2018, 11:06 PM
ardumont edited the summary of this revision. (Show Details)