Browse Source

Add xtrabackup repo on RHEL

tags/1.0
Filip Pytloun 9 years ago
parent
commit
da67965594
3 changed files with 22 additions and 2 deletions
  1. +4
    -2
      galera/map.jinja
  2. +9
    -0
      galera/master.sls
  3. +9
    -0
      galera/slave.sls

+ 4
- 2
galera/map.jinja View File

'config': '/etc/mysql/my.cnf', 'config': '/etc/mysql/my.cnf',
}, },
'RedHat': { 'RedHat': {
'pkgs': ['galera', 'mariadb-server', 'mariadb', 'MySQL-python', 'rsync'],
'pkgs': ['galera', 'mariadb-galera-server', 'mariadb', 'MySQL-python', 'rsync', 'percona-xtrabackup-21'],
'xtrabackup_repo': 'http://www.percona.com/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm',
'service': 'mariadb', 'service': 'mariadb',
'wsrep_provider': '/usr/lib64/galera/libgalera_smm.so', 'wsrep_provider': '/usr/lib64/galera/libgalera_smm.so',
'log_file': '/var/log/mariadb/mariadb.log', 'log_file': '/var/log/mariadb/mariadb.log',
'config': '/etc/mysql/my.cnf', 'config': '/etc/mysql/my.cnf',
}, },
'RedHat': { 'RedHat': {
'pkgs': ['galera', 'mariadb-server', 'mariadb', 'MySQL-python', 'rsync'],
'pkgs': ['galera', 'mariadb-galera-server', 'mariadb', 'MySQL-python', 'rsync', 'percona-xtrabackup-21'],
'xtrabackup_repo': 'http://www.percona.com/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm',
'service': 'mariadb', 'service': 'mariadb',
'wsrep_provider': '/usr/lib64/galera/libgalera_smm.so', 'wsrep_provider': '/usr/lib64/galera/libgalera_smm.so',
'log_file': '/var/log/mariadb/mariadb.log', 'log_file': '/var/log/mariadb/mariadb.log',

+ 9
- 0
galera/master.sls View File

{%- from "galera/map.jinja" import master with context %} {%- from "galera/map.jinja" import master with context %}
{%- if master.enabled %} {%- if master.enabled %}


{%- if grains.os_family == 'RedHat' %}
xtrabackup_repo:
pkg.installed:
- sources:
- percona-xtrabackup: {{ master.xtrabackup_repo }}
- require_in:
- pkg: galera_packages
{%- endif %}

galera_packages: galera_packages:
pkg.installed: pkg.installed:
- names: {{ master.pkgs }} - names: {{ master.pkgs }}

+ 9
- 0
galera/slave.sls View File

{%- from "galera/map.jinja" import slave with context %} {%- from "galera/map.jinja" import slave with context %}
{%- if slave.enabled %} {%- if slave.enabled %}


{%- if grains.os_family == 'RedHat' %}
xtrabackup_repo:
pkg.installed:
- sources:
- percona-xtrabackup: {{ slave.xtrabackup_repo }}
- require_in:
- pkg: galera_packages
{%- endif %}

galera_packages: galera_packages:
pkg.installed: pkg.installed:
- names: {{ slave.pkgs }} - names: {{ slave.pkgs }}

Loading…
Cancel
Save