2017-08-28 09:20:50 +00:00
|
|
|
---
|
|
|
|
- name: Add apt key for mariadb for Debian <= 8
|
|
|
|
apt_key: keyserver=hkp://keyserver.ubuntu.com:80 id=0xcbcb082a1bb943db state=present
|
2019-12-04 13:10:07 +00:00
|
|
|
when: ansible_distribution_major_version is version_compare('8', 'le')
|
2017-08-28 09:20:50 +00:00
|
|
|
|
2019-12-18 12:49:17 +00:00
|
|
|
- name: Install dirmngr for apt key for mariadb for Debian > 8
|
|
|
|
apt:
|
|
|
|
pkg: dirmngr
|
|
|
|
state: present
|
|
|
|
when: ansible_distribution_major_version is version_compare('8', 'gt')
|
|
|
|
|
2017-09-05 14:05:28 +00:00
|
|
|
- name: Add apt key for mariadb for Debian > 8
|
|
|
|
apt_key: keyserver=hkp://keyserver.ubuntu.com:80 id=0xF1656F24C74CD1D8 state=present
|
2019-12-04 13:10:07 +00:00
|
|
|
when: ansible_distribution_major_version is version_compare('8', 'gt')
|
2017-09-05 14:05:28 +00:00
|
|
|
|
2017-08-28 09:20:50 +00:00
|
|
|
- name: Add apt repository
|
|
|
|
apt_repository:
|
2018-01-09 05:38:18 +00:00
|
|
|
repo: 'deb [arch=amd64,i386] http://ams2.mirrors.digitalocean.com/mariadb/repo/{{ mariadb_version }}/debian {{ ansible_distribution_release }} main'
|
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Add apt repository
|
|
|
|
apt_repository:
|
|
|
|
repo: 'deb-src [arch=amd64,i386] http://ams2.mirrors.digitalocean.com/mariadb/repo/{{ mariadb_version }}/debian {{ ansible_distribution_release }} main'
|
2017-08-28 09:20:50 +00:00
|
|
|
state: present
|
|
|
|
|
|
|
|
- name: Unattended package installation
|
|
|
|
shell: export DEBIAN_FRONTEND=noninteractive
|
|
|
|
|
|
|
|
- name: apt-get install
|
2019-12-04 12:54:56 +00:00
|
|
|
apt:
|
|
|
|
pkg:
|
|
|
|
- mariadb-server
|
|
|
|
- mariadb-client
|
|
|
|
- mariadb-common
|
|
|
|
- libmariadbclient18
|
|
|
|
- python3-mysqldb
|
|
|
|
update_cache: yes
|
|
|
|
state: present
|
2018-02-05 09:37:14 +00:00
|
|
|
...
|