Merge "Correct the ca-cert for mqtt on subunit worker"
This commit is contained in:
commit
459926216e
@ -485,9 +485,10 @@ node /^subunit-worker\d+\.openstack\.org$/ {
|
|||||||
sysadmins => hiera('sysadmins', []),
|
sysadmins => hiera('sysadmins', []),
|
||||||
}
|
}
|
||||||
class { 'openstack_project::subunit_worker':
|
class { 'openstack_project::subunit_worker':
|
||||||
subunit2sql_db_host => hiera('subunit2sql_db_host', ''),
|
subunit2sql_db_host => hiera('subunit2sql_db_host', ''),
|
||||||
subunit2sql_db_pass => hiera('subunit2sql_db_password', ''),
|
subunit2sql_db_pass => hiera('subunit2sql_db_password', ''),
|
||||||
mqtt_pass => hiera('mqtt_service_user_password'),
|
mqtt_pass => hiera('mqtt_service_user_password'),
|
||||||
|
mqtt_ca_cert_contents => hiera('mosquitto_tls_ca_file'),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -19,6 +19,7 @@ class openstack_project::subunit_worker (
|
|||||||
$subunit2sql_db_pass,
|
$subunit2sql_db_pass,
|
||||||
$mqtt_user = 'infra',
|
$mqtt_user = 'infra',
|
||||||
$mqtt_pass = undef,
|
$mqtt_pass = undef,
|
||||||
|
$mqtt_ca_cert_contents = undef,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
file { '/etc/subunit2sql/subunit-woker.yaml':
|
file { '/etc/subunit2sql/subunit-woker.yaml':
|
||||||
@ -29,6 +30,15 @@ class openstack_project::subunit_worker (
|
|||||||
content => template('openstack_project/logstash/jenkins-subunit-worker.yaml.erb'),
|
content => template('openstack_project/logstash/jenkins-subunit-worker.yaml.erb'),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
file { '/etc/subunit2sql/mqtt-root-CA.pem.crt':
|
||||||
|
ensure => present,
|
||||||
|
content => $mqtt_ca_cert_contents,
|
||||||
|
replace => true,
|
||||||
|
owner => 'subunit',
|
||||||
|
group => 'subunit',
|
||||||
|
mode => '0555',
|
||||||
|
}
|
||||||
|
|
||||||
include subunit2sql
|
include subunit2sql
|
||||||
subunit2sql::worker { 'A':
|
subunit2sql::worker { 'A':
|
||||||
config_file => '/etc/subunit2sql/subunit-woker.yaml',
|
config_file => '/etc/subunit2sql/subunit-woker.yaml',
|
||||||
|
@ -6,4 +6,4 @@ mqtt-port: 8883
|
|||||||
mqtt-topic: gearman-subunit/<%= @hostname %>
|
mqtt-topic: gearman-subunit/<%= @hostname %>
|
||||||
mqtt-user: <%= @mqtt_user %>
|
mqtt-user: <%= @mqtt_user %>
|
||||||
mqtt-pass: <%= @mqtt_pass %>
|
mqtt-pass: <%= @mqtt_pass %>
|
||||||
mqtt-ca_certs: "/etc/ca-certificates/extracted/tls-ca-bundle.pem"
|
mqtt-ca_certs: /etc/subunit2sql/mqtt-root-CA.pem.crt
|
||||||
|
Loading…
x
Reference in New Issue
Block a user