Hacker News new | ask | show | jobs
by medellin 809 days ago
It is annoying is you want to run your teat inside a container for ci and now you are running a container in a container and all the issues that come with it.
2 comments

Why would the postgres container need to be nested inside another container? Why not just have the CI environment also run a Postgres container, along side your tests, and give your tests a `POSTGRES_URL` environment variable? Or why even bother running Postgres in a container, why not just run the Postgres binary on the host that's running your tests in the container?
which issues?
Depending on the setup it can be a pain to get nested containers working sometimes. There is, e.g., Docker In Docker but this often required a privileged host container which is often not provided in CI/CD pipelines.
Which issues/pains with getting nested containers?

I am aware of only a few settings that make a container nestle, or not, whether it is a vm, lxc/lxd type container, etc.