Skip to content

add mysql options to mysql_user module #26581

@mohsenSy

Description

@mohsenSy
ISSUE TYPE
  • Feature Idea
COMPONENT NAME

mysql_user

ANSIBLE VERSION
ansible 2.4.0 (devel 2420bca0b5) last updated 2017/07/10 11:06:47 (GMT +300)
  config file = /etc/ansible/ansible.cfg
  configured module search path = [u'/home/mohsen/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
  ansible python module location = /home/mohsen/SourceCode/ansible/lib/ansible
  executable location = /home/mohsen/SourceCode/ansible/bin/ansible
  python version = 2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609]
OS / ENVIRONMENT

Ubuntu16.04 managing Ubuntu14.04

SUMMARY

When creating a new user using mysql_user module I cannot add extra options to user created such as MAX_USER_CONNECTIONS,MAX_CONNECTIONS_PER_HOUR etc...

STEPS TO REPRODUCE

This can be used to setup resource limits for new users as described in this web page: https://dev.mysql.com/doc/refman/5.7/en/user-resources.html

   mysql_user:
      name: mohsen
      password: mohsen_pass
      state: present
      options:
         - MAX_USER_CONNECTIONS: 50
EXPECTED RESULTS

A new user called mohsen should be created and it must be limited to 50 total connections

Metadata

Metadata

Assignees

No one assigned

    Labels

    affects_2.4This issue/PR affects Ansible v2.4databaseDatabase categoryfeatureThis issue/PR relates to a feature request.moduleThis issue/PR relates to a module.mysqlsupport:communityThis issue/PR relates to code supported by the Ansible community.testThis PR relates to tests.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions