This container image can be used to automatically drop mongoDB databases and clean up rabbitmq resources like an exchange, its bindings and destination queues.
These environment variables are mandatory and must be set before running this container.
Variable | Purpose |
---|---|
MONGO_URI | URI which is used in order to connect to a Mongo database instance |
MONGO_DB | Databasename inside MongoDB which will be dropped |
MESSAGE_QUEUE_URI | URI which is used in order to connect to a RabbitMQ instance |
EXCHANGE_NAME | Name of RabbitMQ exchange that will be deleted together with its bindings and their destinations |
-
update dockerfile
-
build local version:
docker build -t inforitnl/dev-deployment-cleanup .
-
push new version to dockerhub:
docker push inforitnl/dev-deployment-cleanup
-
tag and push again (optional but recommended):
docker tag inforitnl/dev-deployment-cleanup inforitnl/dev-deployment-cleanup:1.0.0 docker push inforitnl/dev-deployment-cleanup:1.0.0