mirror of
https://github.com/saltstack-formulas/mysql-formula.git
synced 2025-04-17 10:10:30 +00:00
Merge pull request #51 from alexhayes/feature/mysql-dev
MySQL development libraries and header files state.
This commit is contained in:
commit
d058e0ddbc
5 changed files with 35 additions and 0 deletions
|
@ -87,3 +87,12 @@ Remove the database called ``test``, normally created as part of a default
|
||||||
MySQL installation. This state is **not** included as part of the meta-state
|
MySQL installation. This state is **not** included as part of the meta-state
|
||||||
above as this name may conflict with a real database.
|
above as this name may conflict with a real database.
|
||||||
|
|
||||||
|
``mysql.dev``
|
||||||
|
------------------------------
|
||||||
|
|
||||||
|
Install the MySQL development libraries and header files.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
Note that this state is not installed by the mysql meta-state unless you set
|
||||||
|
your pillar data accordingly.
|
||||||
|
|
||||||
|
|
|
@ -9,6 +9,7 @@ Ubuntu:
|
||||||
service: mysql
|
service: mysql
|
||||||
python: python-mysqldb
|
python: python-mysqldb
|
||||||
debconf_utils: debconf-utils
|
debconf_utils: debconf-utils
|
||||||
|
dev: libmysqlclient-dev
|
||||||
config:
|
config:
|
||||||
file: /etc/mysql/my.cnf
|
file: /etc/mysql/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
@ -53,6 +54,7 @@ Debian:
|
||||||
service: mysql
|
service: mysql
|
||||||
python: python-mysqldb
|
python: python-mysqldb
|
||||||
debconf_utils: debconf-utils
|
debconf_utils: debconf-utils
|
||||||
|
dev: libmysqlclient-dev
|
||||||
config:
|
config:
|
||||||
file: /etc/mysql/my.cnf
|
file: /etc/mysql/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
@ -95,6 +97,7 @@ CentOS:
|
||||||
client: mysql
|
client: mysql
|
||||||
service: mysqld
|
service: mysqld
|
||||||
python: MySQL-python
|
python: MySQL-python
|
||||||
|
dev: mysql-devel
|
||||||
config:
|
config:
|
||||||
file: /etc/my.cnf
|
file: /etc/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
@ -113,6 +116,7 @@ RedHat:
|
||||||
client: mysql
|
client: mysql
|
||||||
service: mysqld
|
service: mysqld
|
||||||
python: MySQL-python
|
python: MySQL-python
|
||||||
|
dev: mysql-devel
|
||||||
config:
|
config:
|
||||||
file: /etc/my.cnf
|
file: /etc/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
@ -149,6 +153,7 @@ Amazon:
|
||||||
client: mysql
|
client: mysql
|
||||||
service: mysqld
|
service: mysqld
|
||||||
python: MySQL-python
|
python: MySQL-python
|
||||||
|
dev: mysql-devel
|
||||||
config:
|
config:
|
||||||
file: /etc/my.cnf
|
file: /etc/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
@ -167,6 +172,7 @@ Gentoo:
|
||||||
client: dev-db/mysql
|
client: dev-db/mysql
|
||||||
service: mysql
|
service: mysql
|
||||||
python: dev-python/mysql-python
|
python: dev-python/mysql-python
|
||||||
|
dev: dev-db/mysqlced
|
||||||
config:
|
config:
|
||||||
file: /etc/mysql/my.cnf
|
file: /etc/mysql/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
@ -248,6 +254,7 @@ FreeBSD:
|
||||||
client: mysql56-client
|
client: mysql56-client
|
||||||
service: mysql-server
|
service: mysql-server
|
||||||
python: pymysql
|
python: pymysql
|
||||||
|
dev: mysql56-server
|
||||||
config:
|
config:
|
||||||
file: /usr/local/etc/my.cnf
|
file: /usr/local/etc/my.cnf
|
||||||
sections:
|
sections:
|
||||||
|
|
7
mysql/dev.sls
Normal file
7
mysql/dev.sls
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
{% from "mysql/defaults.yaml" import rawmap with context %}
|
||||||
|
{%- set mysql = salt['grains.filter_by'](rawmap, grain='os', merge=salt['pillar.get']('mysql:server:lookup')) %}
|
||||||
|
|
||||||
|
mysql_dev:
|
||||||
|
pkg:
|
||||||
|
- installed
|
||||||
|
- name: {{ mysql.dev }}
|
|
@ -7,10 +7,16 @@
|
||||||
{%- endfor -%}
|
{%- endfor -%}
|
||||||
{% endmacro %}
|
{% endmacro %}
|
||||||
|
|
||||||
|
{% set mysql_dev = salt['pillar.get']('mysql:dev:install', False) %}
|
||||||
|
|
||||||
include:
|
include:
|
||||||
- mysql.server
|
- mysql.server
|
||||||
- mysql.database
|
- mysql.database
|
||||||
- mysql.user
|
- mysql.user
|
||||||
|
{% if mysql_dev %}
|
||||||
|
- mysql.dev
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
{% if (db_states|length() + user_states|length()) > 0 %}
|
{% if (db_states|length() + user_states|length()) > 0 %}
|
||||||
extend:
|
extend:
|
||||||
|
|
|
@ -58,3 +58,9 @@ mysql:
|
||||||
client: mysql-client
|
client: mysql-client
|
||||||
service: mysql-service
|
service: mysql-service
|
||||||
python: python-mysqldb
|
python: python-mysqldb
|
||||||
|
|
||||||
|
# Install MySQL headers
|
||||||
|
dev:
|
||||||
|
# Install dev package - defaults to False
|
||||||
|
install: False
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue