Giuseppe Lavagetto has submitted this change and it was merged. Change subject: pybal: introduce role for testing machines ......................................................................
pybal: introduce role for testing machines This should guarantee that a functioning setup of pybal is provided, including a pybal configuration that should include all services from the whole datacenter. Change-Id: I0882db68c5a8d87b4312925a666ef13250f8305c --- M hieradata/labs/deployment-prep/common.yaml M modules/pybal/templates/pybal.conf.erb A modules/role/manifests/pybal/testing.pp 3 files changed, 42 insertions(+), 2 deletions(-) Approvals: Giuseppe Lavagetto: Verified; Looks good to me, approved diff --git a/hieradata/labs/deployment-prep/common.yaml b/hieradata/labs/deployment-prep/common.yaml index cf1c0d0..d6d2562 100644 --- a/hieradata/labs/deployment-prep/common.yaml +++ b/hieradata/labs/deployment-prep/common.yaml @@ -29,7 +29,22 @@ - wikivoyage.org - wiktionary.org graphoid::protocol: http -lvs::configuration::lvs_services: dummy +lvs::configuration::lvs_services: + apaches: + description: "Main MediaWiki application server cluster" + class: low-traffic + sites: + - eqiad + ip: + eqiad: 1.2.3.4 + depool-threshold: '.2' + monitors: + ProxyFetch: + url: + - http://en.wikipedia.beta.wmflabs.org/wiki/Special:BlankPage + IdleConnection: + timeout-clean-reconnect: 3 + max-delay: 300 lvs::configuration::lvs_service_ips: apaches: eqiad: dummy diff --git a/modules/pybal/templates/pybal.conf.erb b/modules/pybal/templates/pybal.conf.erb index 17fba3c..6daaede 100644 --- a/modules/pybal/templates/pybal.conf.erb +++ b/modules/pybal/templates/pybal.conf.erb @@ -9,7 +9,7 @@ bgp-nexthop-ipv4 = <%= @global_options['bgp-nexthop-ipv4'] %> bgp-nexthop-ipv6 = <%= @global_options['bgp-nexthop-ipv6'] %> instrumentation = <%= @global_options.fetch('instrumentation', 'yes') %> - +<% if @global_options.fetch('dry-run', nil) %>dry-run = <%= @global_options.fetch('dry-run', 'no') %><% end %> # # LVS service definitions # diff --git a/modules/role/manifests/pybal/testing.pp b/modules/role/manifests/pybal/testing.pp new file mode 100644 index 0000000..a441192 --- /dev/null +++ b/modules/role/manifests/pybal/testing.pp @@ -0,0 +1,25 @@ +# == Class role::pybal::testing +# +# Class for a pybal test host + +class role::pybal::testing { + include ::pybal + $opts = { + 'instrumentation' => 'yes', + 'bgp' => 'no', + 'dry-run' => 'yes', + } + + $lvs_class_hosts_stub = { + 'high-traffic1' => [$::hostname], + 'high-traffic2' => [$::hostname], + 'low-traffic' => [$::hostname], + } + + class { 'pybal::configuration': + global_options => $opts, + lvs_services => hiera('lvs::configuration::lvs_services'), + lvs_class_hosts => $lvs_class_hosts_stub, + site => 'eqiad' + } +} -- To view, visit https://gerrit.wikimedia.org/r/259704 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I0882db68c5a8d87b4312925a666ef13250f8305c Gerrit-PatchSet: 5 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Giuseppe Lavagetto <[email protected]> Gerrit-Reviewer: Giuseppe Lavagetto <[email protected]> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
