Deleted unneeded parts

This commit is contained in:
Sergei Antipov 2016-04-17 20:40:20 +06:00
parent e5f2d18095
commit 630e773962
5 changed files with 4 additions and 77 deletions

View File

@ -19,12 +19,9 @@ mongodb_package: mongodb-org
# I will recommend you to use latest version of MongoDB.
mongodb_version: "3.2"
mongodb_force_wait_for_port: false # When not forced, the role will wait for mongod port to become available only with systemd
mongodb_pymongo_from_pip: true # Install latest PyMongo via PIP or package manager
mongodb_pymongo_pip_version: "3.2.2"
mongodb_disable_thp: true
mongodb_force_wait_for_port: false # When not forced, the role will wait for mongod port to become available only with systemd
mongodb_pymongo_from_pip: true # Install latest PyMongo via PIP or package manager
mongodb_user_update_password: "on_create" # MongoDB user password update default policy
mongodb_manage_service: true
mongodb_user: mongodb
@ -77,16 +74,6 @@ mongodb_mms_group_id: ""
mongodb_mms_api_key: ""
mongodb_mms_base_url: https://mms.mongodb.com
# Log rotation
mongodb_logrotate: true # Rotate mongodb logs.
mongodb_logrotate_options:
- compress
- copytruncate
- daily
- dateext
- rotate 7
- size 10M
# password for inter-process authentication
# please regenerate this file on production environment with command 'openssl rand -base64 741'
mongodb_keyfile_content: |

View File

@ -7,7 +7,6 @@ mongodb_apt_key_id: "{{ 'EA312927' if mongodb_version[0:3] == '3.2' else '7F0CEB
mongodb_pymongo_from_pip: true # Install latest PyMongo via PIP or package manager
mongodb_force_wait_for_port: false
mongodb_disable_thp: true
mongodb_user_update_password: "on_create" # MongoDB user password update default policy
mongodb_manage_service: true
@ -62,16 +61,6 @@ mongodb_mms_group_id: ""
mongodb_mms_api_key: ""
mongodb_mms_base_url: https://mms.mongodb.com
# Log rotation
mongodb_logrotate: true # Rotate mongodb logs.
mongodb_logrotate_options:
- compress
- copytruncate
- daily
- dateext
- rotate 7
- size 10M
# password for inter-process authentication
# please regenerate this file on production environment with command 'openssl rand -base64 741'
mongodb_keyfile_content: |

View File

@ -9,10 +9,6 @@
mode: 0600
when: mongodb_replication_replset and mongodb_replication_replset != ''
- name: Configure log rotation
template: src=logrotate.conf.j2 dest=/etc/logrotate.d/mongodb.conf
when: mongodb_logrotate
- name: set mongodb gid
group: name=mongodb gid={{ mongodb_gid }} state=present
when: mongodb_gid
@ -40,29 +36,6 @@
template: src=mongod.conf.j2 dest=/etc/mongod.conf backup=yes owner=root group=root mode=0644
register: config_result
- name: Install sysfsutils package
apt: name=sysfsutils state=present
when: ansible_os_family == 'Debian' and mongodb_disable_thp
- name: Create /etc/sysfs.d direcroty
file:
path: /etc/sysfs.d
group: root
state: directory
mode: 0755
owner: root
when: ansible_os_family == 'Debian' and mongodb_disable_thp
- name: Create sysfs config
copy:
src: hugepages.conf
dest: /etc/sysfs.d/hugepages.conf
owner: root
group: root
mode: 0644
when: ansible_os_family == 'Debian' and mongodb_disable_thp
notify: restart sysfsutils
- name: mongodb restart
service: name={{ mongodb_daemon_name }} state=restarted
when: config_result|changed and mongodb_manage_service

View File

@ -1,8 +0,0 @@
# This file was generated by Ansible for {{ ansible_fqdn }}
# Do NOT modify this file by hand!
{{ mongodb_systemlog_path }} {
{% for option in mongodb_logrotate_options %}
{{ option }}
{% endfor %}
}

View File

@ -22,18 +22,4 @@
roles:
- role: greendayonfire.mongodb
when: "'mongo' in group_names"
- hosts: localhost
become: no
gather_facts: no
tasks:
- name: Run MongoDB cluster in Docker
docker:
name: "{{ item }}"
image: "{{ image_name }}"
command: "/sbin/init"
state: absent
with_items:
- mongo1
- mongo2
- mongo3