Hacker News new | ask | show | jobs
by imp0cat 841 days ago
Because you don't have to muck around with docker-compose. I guess some people might find that more attractive.
2 comments

You'd probably need it for the development environment anyway so you might as well reuse it
Meanwhile docker compose selling point: 'because you don't have to muck around with testcontainers; I guess some people might find that more attractive'.
Oh, absolutely! And as the other guy pointed out, docker-compose can be quite reusable when developing locally if you write it right.

But at $WORKPLACE we often use pytest-xprocess to start the required app in the same container where the tests run. It's probably the easiest way mostly because a custom wrapper does all the heavy lifting (starts the app, checks that it is running and responding to requests before the tests start, correctly terminates it when tests end).