Browse Source

Fix kitchen CI

There is no guarntee that pillars are loaded before pillars-from-file
as result we cant assume variables defined via pillars: are available
when pillars-from-file is loaded. Move 'source' definitions of repos to
.kitchen.yml as it uses ENV variable

Change-Id: Id94edd2351f17f5ac130db41a97d3be9cd5f3be4
master
Vasyl Saienko 7 years ago
parent
commit
812de58650
2 changed files with 13 additions and 2 deletions
  1. +13
    -0
      .kitchen.yml
  2. +0
    -2
      tests/pillar/repo_galeracluster.sls

+ 13
- 0
.kitchen.yml View File

@@ -31,6 +31,7 @@ provisioner:
base:
"*":
- versions
- repos_base
- repos
- galera
versions.sls:
@@ -38,6 +39,18 @@ provisioner:
version:
mysql: <%= ENV['MYSQL_VER'] || '5.6' %>
galera: <%= ENV['GALERA_VER'] || '3' %>
# NOTE(vsaienko) There is no guarntee that pillars are loaded before pillars-from-file
# as result we cant assume variables defined via pillars: are available when pillars-from-file
# is loaded. Move 'source' definitions of repos to .kitchen.yml as it used ENV variable
repos_base.sls:
linux:
system:
enabled: true
repo:
galeracluster:
source: deb http://releases.galeracluster.com/galera-<%=ENV['GALERA_VER'] || '3'%>/ubuntu {{ grains.get('oscodename') }} main
mysql-wsrep:
source: deb http://releases.galeracluster.com/mysql-wsrep-<%=ENV['MYSQL_VER'] || '5.6'%>/ubuntu {{ grains.get('oscodename') }} main
pillars-from-files:
repos.sls: tests/pillar/repo_galeracluster.sls


+ 0
- 2
tests/pillar/repo_galeracluster.sls View File

@@ -3,7 +3,6 @@ linux:
enabled: true
repo:
galeracluster:
source: 'deb http://releases.galeracluster.com/galera-{{ pillar.galera.version.galera }}/ubuntu {{ grains.get('oscodename') }} main'
key_id: BC19DDBA
key_server: hkp://p80.pool.sks-keyservers.net:80
pin:
@@ -11,7 +10,6 @@ linux:
priority: 1001
package: '*'
mysql-wsrep:
source: 'deb http://releases.galeracluster.com/mysql-wsrep-{{ pillar.galera.version.mysql }}/ubuntu {{ grains.get('oscodename') }} main'
key_id: BC19DDBA
key_server: hkp://p80.pool.sks-keyservers.net:80
pin:

Loading…
Cancel
Save