community.mongodb.mongodb_shutdown – Cleans up all database resources and then terminates the mongod/mongos process.¶
Note
This plugin is part of the community.mongodb collection (version 1.2.0).
To install it use: ansible-galaxy collection install community.mongodb
.
To use it in a playbook, specify: community.mongodb.mongodb_shutdown
.
New in version 1.0.0: of community.mongodb
Parameters¶
Notes¶
Note
Requires the pymongo Python package on the remote host, version 2.4.2+. This can be installed using pip or the OS package manager. @see http://api.mongodb.org/python/current/installation.html
Examples¶
- name: Attempt to perform a clean shutdown
community.mongodb.mongodb_shutdown:
- name: Force shutdown with a timeout of 60 seconds
mongodb_maintenance:
force: true
timeout: 60
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
changed
boolean
|
success |
Whether the member was shutdown.
|
failed
boolean
|
failed |
If something went wrong
|
msg
string
|
success |
A short description of what happened.
|
Authors¶
Rhys Campbell (@rhysmeister)