Skip to content
Snippets Groups Projects
Verified Commit 0ce47ee1 authored by sistason's avatar sistason
Browse files

integrate working with keyFiles

parent b7bd4109
Branches
No related tags found
No related merge requests found
...@@ -23,3 +23,4 @@ mongodb: ...@@ -23,3 +23,4 @@ mongodb:
keep_days: 2 keep_days: 2
replicaset: {} replicaset: {}
user: {} user: {}
keyfile_contents: ""
...@@ -3,6 +3,15 @@ ...@@ -3,6 +3,15 @@
executable: pip3 executable: pip3
name: pymongo name: pymongo
- name: template keyfile if necessary
copy:
dest: "{{ mongodb.config.security.keyFile }}"
content: "{{ mongodb.keyfile_contents }}"
owner: mongodb
group: mongodb
mode: "0600"
when: mongodb.keyfile_contents and mongodb.config.security.keyFile
- name: copy mongodb config - name: copy mongodb config
notify: notify:
- restart mongodb - restart mongodb
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment