tripleo-image-elements/elements/mysql-common
Gonéri Le Bouder e58007c9c4 tox: fix the test suite
fix pep8 syntax (H904 Wrap long lines in parentheses instead of a backslash).

fix two regressions in test_os_svc_daemon.py introduced by
    Ibd491881d79160ad1457526d51512f5fc1cf9ea5:
  - ensure os-svc-daemon won't try to write in /etc/os-logging by passing
    the “-l” extra parameter.
  - fix the test_standard_upstart test from test_os_svc_daemon.py to
     match the expected outpout.

Change-Id: I113504947d126e9d91409f97f8291d5b8fc15c42
2015-02-02 12:05:21 +00:00
..
install.d Install and configure MySQL `clustercheck` 2014-11-12 15:44:53 +00:00
os-apply-config Merge "Secure MySQL clustering with SSL" 2015-01-06 16:17:04 +00:00
os-refresh-config tox: fix the test suite 2015-02-02 12:05:21 +00:00
README.md Support custom privileges for managed MySQL users 2014-11-10 12:55:36 +00:00
element-deps Migrate to package-installs scripts 2014-11-05 01:38:05 -08:00

README.md

This element contains code common for mysql and mariadb elements, make sure you include once of them when including this element.

TODO: auto-tune settings based on host resources or metadata service.

Configuration

Users will be created if Heat Metadata is passed in under the 'mysql.create-users' section. For example:

mysql:
  create-users:
    - username: dbuser1
      database: somedb
      userhandle:
        Ref: SomeWaitConditionHandle

This will cause mysql to create the user 'dbuser1' if it does not exist, and grant it all privileges on somedb. If no 'database' parameter is supplied, the user will be given access to all databases. It will have a random password generated and passed to the WaitConditionHandle with the key of the username, and password as the data. A password can also be given for the user like this:

mysql:
  create-users:
    - username: dbuser2
      database: somedb
      password: abcdefg12345

If a userhandle is also given with the password, it will be passed to the wait condition handle in the same manner.

Privileges may be restricted for the user like so:

mysql:
  create-users:
    - username: dbuser2
      database: somedb
      password: abcdefg12345
      privilege: "USAGE, SELECT"