GithubHelp home page GithubHelp logo

stone-payments / ansible-mongodb Goto Github PK

View Code? Open in Web Editor NEW
23.0 23.0 14.0 122 KB

:green_book: Ansible role to setup a MongoDB with replica set support -- Arquivado por Foundation Platform dia 2023-11-28

License: MIT License

Python 82.79% Jinja 17.21%
ansible databases mongodb replica-set

ansible-mongodb's People

Contributors

bcdonadio avatar bsvicencio avatar cnatan avatar daianmartinho avatar jamilcuri avatar jokimaki avatar vinifigueira avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ansible-mongodb's Issues

Error when deploy with replset enabled

I have 2 servers with ubuntu 16.04.4 LTS

my ansible playbook:

- hosts: mongo

  roles:
  - stone-payments.mongodb
  vars:
  - mongodb_conf_bindIp: "0.0.0.0"
  - mongodb_replSet_enabled: true
  - mongodb_replSet_name: "someReplicaSetName"
  - mongodb_replSet_master: "192.168.1.65"
  - mongodb_replSet_isMaster: "{{ true if mongodb_replSet_master in ansible_all_ipv4_addresses else false }}"

When I run this playbookt, I get an error:

TASK [stone-payments.mongodb : connect to master] *******************************************************************************************************************************************************************************************
fatal: [ubuntu2]: FAILED! => {"changed": false, "module_stderr": "Shared connection to 192.168.1.66 closed.\r\n", "module_stdout": "Traceback (most recent call last):\r\n  File \"/tmp/ansible_Fq6YXJ/ansible_module_mongodb_replica_set.py\", line 447, in <module>\r\n    main()\r\n  File \"/tmp/ansible_Fq6YXJ/ansible_module_mongodb_replica_set.py\", line 442, in main\r\n    result['changed'] = rs_alter(client, member, state, 0)\r\n  File \"/tmp/ansible_Fq6YXJ/ansible_module_mongodb_replica_set.py\", line 343, in rs_alter\r\n    current_member = rs_get_member(rs_config, member['host'])\r\n  File \"/tmp/ansible_Fq6YXJ/ansible_module_mongodb_replica_set.py\", line 289, in rs_get_member\r\n    a = filter(lambda x: x['host'] == member, rs_config['members'])\r\nTypeError: 'NoneType' object has no attribute '__getitem__'\r\n", "msg": "MODULE FAILURE", "rc": 0}

Doesn't handle existing files from another system

The existing configuration does not change the permissions of the data directory recursively when it's not empty (e.g. restoring files from a snapshot). This can cause MongoDB to break with permission problems.

The configuration also does not account for the log path directory, that must also be writable.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.