# - env: INSTANCE=default-arch-base-latest-3000-3-py2 | # - env: INSTANCE=default-arch-base-latest-3000-3-py2 | ||||
# - env: INSTANCE=upstart-centos-6-2019-2-py2 | # - env: INSTANCE=upstart-centos-6-2019-2-py2 | ||||
# - env: INSTANCE=upstart-amazonlinux-1-2019-2-py2 | # - env: INSTANCE=upstart-amazonlinux-1-2019-2-py2 | ||||
- env: INSTANCE=mysql-debian-10-master-py3 | |||||
- env: INSTANCE=mysql-ubuntu-2004-master-py3 | |||||
## Define the release stage that runs `semantic-release` | ## Define the release stage that runs `semantic-release` | ||||
- stage: 'release' | - stage: 'release' |
inspec_tests: | inspec_tests: | ||||
- path: test/integration/_mapdata | - path: test/integration/_mapdata | ||||
- path: test/integration/default | - path: test/integration/default | ||||
- name: mysql | |||||
includes: | |||||
- debian-10-master-py3 | |||||
- ubuntu-2004-master-py3 | |||||
provisioner: | |||||
state_top: | |||||
base: | |||||
'*': | |||||
- diaspora | |||||
- mysql | |||||
pillars: | |||||
top.sls: | |||||
base: | |||||
'*': | |||||
- diaspora | |||||
- tests | |||||
- mysql | |||||
pillars_from_files: | |||||
diaspora.sls: pillar.example | |||||
tests.sls: test/salt/pillar/tests.sls | |||||
mysql.sls: test/salt/pillar/mysql.sls | |||||
dependencies: | |||||
- name: mysql | |||||
path: test/salt/states | |||||
verifier: | |||||
inspec_tests: | |||||
- path: test/integration/default |
# -*- coding: utf-8 -*- | |||||
# vim: ft=yaml | |||||
--- | |||||
diaspora: | |||||
database: | |||||
type: mysql |
mysql_package: | |||||
pkg.installed: | |||||
- pkgs: | |||||
- mariadb-server | |||||
- python3-mysqldb | |||||
mysql_service: | |||||
service.running: | |||||
- name: mariadb | |||||
- require: | |||||
- pkg: mysql_package | |||||
mysql_user: | |||||
mysql_user.present: | |||||
- name: {{ salt['pillar.get']('diaspora:database:username') }} | |||||
- password: {{ salt['pillar.get']('diaspora:database:password') }} | |||||
- require: | |||||
- service: mysql_service | |||||
mysql_grants.present: | |||||
- grant: all privileges | |||||
- database: {{ salt['pillar.get']('diaspora:database:database') }}.* | |||||
- user: {{ salt['pillar.get']('diaspora:database:username') }} | |||||
- require: | |||||
- mysql_user: mysql_user | |||||
- require_in: | |||||
- cmd: diaspora_create_database |