mercredi 17 mars 2021

Wait for docker container restart in python

I am in the process of programming some tests in Python. In one test, I am using a container that loads data from a database when the container starts.

In the test I modify the data in the database and restart the container with os.system("docker-compose restart predict") , so the latest data is loaded in the container.

Is there (besides the wait-for-it.sh repo) an option to wait with the execution until the container is up and running, directly in python?

Aucun commentaire:

Enregistrer un commentaire