aboutsummaryrefslogtreecommitdiffstats
path: root/lib
AgeCommit message (Collapse)AuthorFilesLines
2017-07-14Merge "Contrail: Fix controlplane/dataplane network asignments & enable ↵Jenkins1-0/+14
optional dpdk"
2017-07-05Contrail: Fix controlplane/dataplane network asignments & enable optional dpdkMichael Henkel1-0/+14
This patch will move the Contrail roles communication towards OpenStack APIs from the public/external network to the internal_api network. I will also add the option to enable dpdk for Contrail. Change-Id: Ia835df656031cdf28de20f41ec6ab1c028dced23 Closes-Bug: 1698422
2017-06-29Do not fail if PCI device is missingBrent Eagles1-1/+1
Fixes a problem where SR-IOV VF count configuration will fail if a physical function is in use by a guest when 'puppet apply' is executed. This change substitutes warnings for failures and skips complaints if a PCI device is unavailable. Note: this patch has the side-effect of allowing the same configuration data on hosts that may *not* or *ever* have PCI SR-IOV devices on the hardware. Time will tell how evil this is in practice. Closes-Bug: #1701284 Change-Id: I71edc135432ab2193741c37ce977dd11172401e6
2017-06-02Drop un-needed 'else' in noop_resourceDan Prince1-1/+0
Change-Id: Id45ac93d482ff23c4c834e2d345a926fc408573f
2017-03-03Throw warnings for norpm actionsAlex Schultz1-0/+5
If the norpm provider attempts to do any install/update/remove actions, we should throw a warning in the logs so people are aware that the action did not actually take place. Change-Id: Ieee5cac3412c709ba6b39316e455d7708cc9d22e Closes-Bug: #1669666
2017-02-17Add virtual_packages support to norpm providerAlex Schultz1-0/+2
The norpm provider is supposed to noop package installs/updates but if a package name in puppet does not match the installed package, it is being reported as not installed. The provider then 'installs' it every time which can trigger unwanted service restarts. Change-Id: Icdfa6567168f9ecc555489ed67405f98544bd910 Closes-Bug: #1665405
2017-01-25Merge "Make sure we bind the rabbit inter-cluster to a specific interface"Jenkins1-0/+31
2017-01-20Add a noop_resource functionDan Prince1-0/+53
A function to create noop providers (set as the default) for the named resource. This works alongside of 'puppet apply --tags' to disable some custom resource types that still attempt to run commands during prefetch, etc. Change-Id: Icabdb30369c8ca15e77d169dc441bee8cfd3631f
2017-01-20Make sure we bind the rabbit inter-cluster to a specific interfaceMichele Baldessari1-0/+31
Currently the inter-cluster communication port listens to all ip addresses: tcp 0 0 0.0.0.0:25672 0.0.0.0:* LISTEN 25631/beam.smp In order to limit it to listen only to the network assigned to rabbitmq we need to add the following: {kernel, [ ... {inet_dist_use_interface, {172,17,0,16}}, ... ]} In order to do the conversion from an ip address to the Erlang representation we add a function that takes a string and returns a converted output. The (~400 randomly generated) IPv6/4 addresses at [1] have been parsed both via erl's built-in inet:parse_address() function and our ruby implementation. All converted ip addresses resulted in the same output [2], [3]. The only difference is that Erlang's parse_address() considers network ip addresses (e.g. 10.0.0.0) invalid whereas the ruby function does not. This should not be a problem as the use case here is to bind a service to a specific ip address on an interface and if anything we likely prefer the less strict behaviour, given that at least in theory it is perfectly valid for an interface to have a network address assigned to it. [1] http://acksyn.org/files/tripleo/ip-addresses.txt [2] http://acksyn.org/files/tripleo/ip-addresses-ruby.txt [3] http://acksyn.org/files/tripleo/ip-addresses-erl.txt Change-Id: I211c75b9bab25c545bcc7f90f34edebc92bba788 Partial-Bug: #1645898
2017-01-19Implement NTP profileCarlos Camacho1-0/+4
This puppet manifest will install and configure by default the NTP service. It will also make sure chrony is purged, because it's present on the EL7 images. Change-Id: If3cf7d9690001b051465ea25cf8a8c3bc6f7c33a
2017-01-02Avoid Yum/RPM prefetch in norpm providerDan Prince1-0/+4
When package installation is disabled we still prefetch packages. This disables the package prefetch by returning an empty array which should be fine in the normal case and fixes issues when running puppet in some docker containers. Change-Id: Ia483c5f8500b804ba37a80e9ca1ec9c038f0a867
2016-09-12Fix value of ctlplane fqdn factJuan Antonio Osorio Robles1-13/+3
This fact was being retrieving the value of the hostname for the management network. We should instead be using a value set explicitly in t-h-t. Depends-On: Idb3ca22ac136691b0bff6f94524d133a4fa10617 Change-Id: I6fcf7c7853071a9f3377aec475308bc8d10d5b33 Related-Bug: #1621742
2016-09-06Merge "Convert ringbuilder to build devices array"Jenkins1-0/+39
2016-09-05Map ctlplane network to management fqdnJuan Antonio Osorio Robles1-0/+11
We don't really expose a management network, but a ctlplane one. So when someone requests the ctlplane fqdn, we'll give the management one. Since that's what we actually fill in the hosts. Change-Id: Iede5a06d73206f98f283729f1879484f09d4012a
2016-09-05Make fqdn fact names match service net mapJuan Antonio Osorio Robles1-3/+3
This will make it easier to use and consume from t-h-t, making their use more dynamic. This is still safe to do, since these are not used by anything yet. Change-Id: I4d603938c568320d4ae1cc7a396070ad4ac62132
2016-09-02Convert ringbuilder to build devices arraySteven Hardy1-0/+39
Currently we have some hard-coded mangling in t-h-t but we instead need to build the array based on the nodes running swift storage, combined with the SwiftRawDisks parameter. This will enable running SwiftStorage on nodes other than Controller and SwiftStorage roles, and is required for custom-roles due to the hard-coded stuff in the role templates and overcloud.yaml Change-Id: I11deed1df712ecccf85d36a75b3bd2e9d226af36 Partially-Implements: blueprint custom-roles
2016-08-29Configure the numvfs for SRIOV interfaceskarthik s2-0/+67
This patch shall create VFs via the PCI SYS interface. Default value : $::os_service_default Sample Format : ['eth0:4','eth2:128'] For values as in sample format, the sriov_numvfs config files for eth0 and eth2 will have the values 4 and 128 respectively The SR-IOV numvfs configuration shall be persisted in /sbin/ifup-local so that, during the bootup of the compute nodes, the numvfs configuration will be restored. Change-Id: I7450b904475bdf46498d9af633416b3eba12f761 Implements: blueprint tripleo-sriov Signed-off-by: karthik s <ksundara@redhat.com>
2016-07-11Fix retrieval of hostname fact based on network.Sofer Athlan-Guyot1-1/+1
When Facter.value(:domain) is nil the facts fqdn_<network> are failing with : Could not retrieve fact='fqdn_external', resolution='<anonymous>': undefined method `empty?' for nil:NilClass Change-Id: I3e7fa983d4cf91c6ab25f9aa4c353b364f44826e Closes-bug: 1595125
2016-06-22Merge "Drop galera_bootstrapped fact"Jenkins1-19/+0
2016-06-21Drop galera_bootstrapped factJuan Antonio Osorio Robles1-19/+0
It's not in use. Change-Id: I4f5a82e439699967b0c10e1d01dd7b3aaa52b5d3
2016-06-20Add fact to get the fqdn for a host in the different networksJuan Antonio Osorio Robles1-0/+33
This will be useful for getting a certificate for a specific hostname via certmonger. bp tls-via-certmonger Change-Id: I3d563061154533f4dc3a0ee48394afbfa954282a
2016-05-25Add lookup_hiera_hash functionGiulio Fidente1-0/+22
The lookup_hiera_hash function is meant to lookup for the value of a given key from a given Hiera hash. In the manifests this is possible by saving the value of the hash in a variable first but when driving lookups from the Heat templates we can't do it. Change-Id: Ie31bb70314db44a0a18e86090cc74aa4df5de169
2016-04-19IPv6 dual-stack supportEmilien Macchi1-0/+31
TL;DR: If keystone_public_api_vip and/or public_virtual_ip is an array of IPs, HAproxy will be configured to listen on all IPs that are given in the arrays. It allows to specify an array for keystone_public_api_vip and/or public_virtual_ip where one IP is v4 and another one is v6. HAproxy will configured to listen on both and redirect the traffic to the IPv6 network (Dual-Stack). Implementation & background: HAproxy requires binding options as an hash where each IP contains an array of binding options. TripleO does not support Puppet Parser [1] (yet) so we can't manipulate data iterations inside the manifests. This patch creates a custom function, called list_to_hash. Example: keystone_vips = ['192.168.0.1:5000', '192.168.0.2:5000'] $keystone_bind_opts = ['transparent'] Using this function: $keystone_vips_hash = list_to_hash($keystone_vips, $keystone_bind_opts) Would return: $keystone_vips_hash = { '192.168.0.1:5000' => ['transparent'], '192.168.0.2:5000' => ['transparent'], } This function will help us in loadbalancer.pp to construct binding options in dynamic way. It's backward compatible, so you don't have to give an array. But if you do, multiple binding will be configured in HAproxy and you'll also be able to deploy IPv6 Dual-Stack. [1] https://docs.puppetlabs.com/puppet/latest/reference/lang_iteration.html Change-Id: I003b6d7d171652654745861d4231882f9e0d373e
2016-03-17Hack to fix IPv6 parsing in facter.Sofer Athlan-Guyot1-0/+2
This kludge fixes the wrong regexp used in facter to report all IPv6 addresses. While the upstream bug[1] is being work out, this should do the job. Closes-Bug: 1558490 [1] https://tickets.puppetlabs.com/browse/FACT-1372 Change-Id: I85dabbd26bf8f25b2a03d22f547618b666421a83
2015-12-15Adds IPv6 support for interface_for_ip functionGilles Dubreuil2-13/+66
Proper interface matching when an IPv6 address is provided. If Facter version used is < 3 then it adds the netmask6 facts as custom facts. Fix bugs https://bugzilla.redhat.com/show_bug.cgi?id=1280523 Change-Id: Ide26ca1740dc12ea5f47a28f4cecacd6ef0b18f9
2015-12-01Remove `validate_ip_address` validator.Jaume Devesa1-53/+0
It is already merged on the puppetlabs-stdlib module: https://github.com/puppetlabs/puppetlabs-stdlib/commit/88a9a314c3e9cccbea5add95081655f2c14ec4c1 And we don't need to carry with this validation anymore. Change-Id: I2cee12e7601c546e616e2c249157e7739af29490
2015-11-23MidoNet services manifestsJaume Devesa3-0/+91
Provide TripleO overcloud manifests to deploy MidoNet and the cluster services that needs to run. Change-Id: I24f852e74fc4652d4609e1a71897e813448055fe
2015-09-03Add package_manifest resource.Dan Prince3-22/+47
This patch converts the write_package_names function into a proper resource. Using the write_package_names only works if the function comes last in the puppet manifest. By making the same functionality a custom resource we allow for it to exist anywhere in the manifest and provide the same functionality. The new syntax would be: package_manifest{'/tmp/foo': ensure => present} Co-Authored-By: Martin Mágr <mmagr@redhat.com> Change-Id: If3e03b1983fed47082fac8ce63f975557dbc503c
2015-06-25Add a function to write package namesDan Prince1-0/+22
This function writes out package names that have been defined in a given puppet catalog. In order to work this should be place last (or very late) in a manifest to ensure it picks up packages. Change-Id: Ie21b5bf7df71337da02ea43915dc4e70d3052bb7
2015-06-12Configure fencing devicesJiri Stransky1-0/+34
Adds a class to configure fence devices and a helper function which helps to select the devices for configuration on appropriate nodes. Depends on patches outside OpenStack's Gerrit: https://github.com/redhat-openstack/puppet-pacemaker/pull/50 https://github.com/redhat-openstack/puppet-pacemaker/pull/52 Change-Id: I819fc8c126ec47cd207c59b3dcf92ff699649c5a
2015-06-03Add interface_for_ip functionDan Prince1-0/+33
This patch adds a custom Puppet function called interface_for_ip This function will be used within the TripleO puppet implementation to help obtain the correct interface for a given IP address. Change-Id: I0979f69a49052fda888277fa64ebeadc038bc778
2015-04-09Add $::galera_bootstrapped factYanis Guenane1-0/+19
This fact let puppet know if the node is part of a Galera cluster already or not. Change-Id: I4ff0512a0d15ac4797c8c64ed76c0fd3fc31b45c
2015-02-04Add norpm package provider and helper class.Dan Prince1-0/+36
This patch adds a new norpm package provider that extends the Puppet provided default RPM package provider and stubs out all of the package install, update, purging so that no packages will get installed. This may be useful when deploying pre-built images where we effectively just want to use Puppet for configuration (not installation). Includes a ::tripleo::package_provider class that will assist in cleanly disabling package installation via hiera.