Skip to content
Snippets Groups Projects
  1. Dec 22, 2020
  2. Dec 16, 2020
  3. Dec 14, 2020
    • Mark Goddard's avatar
      Revert "Performance: Use import_tasks in the main plays" · db4fc85c
      Mark Goddard authored
      This reverts commit 9cae59be.
      
      Reason for revert: This patch was found to introduce issues with fluentd customisation. The underlying issue is not currently fully understood, but could be a sign of other obscure issues.
      
      Change-Id: Ia4859c23d85699621a3b734d6cedb70225576dfc
      Closes-Bug: #1906288
      db4fc85c
  4. Oct 27, 2020
    • Radosław Piliszek's avatar
      Performance: Use import_tasks in the main plays · 9cae59be
      Radosław Piliszek authored
      Main plays are action-redirect-stubs, ideal for import_tasks.
      
      This avoids 'include' penalty and makes logs/ara look nicer.
      
      Fixes haproxy and rabbitmq not to check the host group as well.
      
      Change-Id: I46136fc40b815e341befff80b54a91ef431eabc0
      Partially-Implements: blueprint performance-improvements
      9cae59be
  5. Oct 12, 2020
    • Radosław Piliszek's avatar
      Performance: optimize genconfig · 3411b9e4
      Radosław Piliszek authored
      Config plays do not need to check containers. This avoids skipping
      tasks during the genconfig action.
      
      Ironic and Glance rolling upgrades are handled specially.
      
      Swift and Bifrost do not use the handlers at all.
      
      Partially-Implements: blueprint performance-improvements
      Change-Id: I140bf71d62e8f0932c96270d1f08940a5ba4542a
      3411b9e4
  6. Oct 04, 2020
    • Radosław Piliszek's avatar
      Coordinate haproxy and keepalived restarts · c2d0bf30
      Radosław Piliszek authored
      Keepalived and haproxy cooperate to provide control plane HA in
      kolla-ansible deployments.
      Certain care should be exerted to avoid prolonged availability
      loss during reconfigurations and upgrades.
      This patch aims to provide this care.
      There is nothing special about keepalived upgrade compared to
      reconfig, hence it is simplified to run the same code as for
      deploy.
      The broken logic of safe upgrade is replaced by common handler
      code which's goal is to ensure we down current master only after
      we have backups ready.
      
      This change introduces a switch to kolla_docker module that allows
      to ignore missing containers (as they are logically stopped).
      ignore_missing is the switch's name.
      All tests are included.
      
      Change-Id: I22ddec5f7ee4a7d3d502649a158a7e005fe29c48
      c2d0bf30
  7. Sep 21, 2020
  8. Aug 28, 2020
  9. Aug 23, 2020
  10. Aug 10, 2020
    • Mark Goddard's avatar
      Mount /etc/timezone based on host OS · 146b00ef
      Mark Goddard authored
      Previously we mounted /etc/timezone if the kolla_base_distro is debian
      or ubuntu. This would fail prechecks if debian or ubuntu images were
      deployed on CentOS. While this is not a supported combination, for
      correctness we should fix the condition to reference the host OS rather
      than the container OS, since that is where the /etc/timezone file is
      located.
      
      Change-Id: Ifc252ae793e6974356fcdca810b373f362d24ba5
      Closes-Bug: #1882553
      146b00ef
  11. Jul 28, 2020
    • Mark Goddard's avatar
      Performance: use import_tasks for check-containers.yml · 9702d4c3
      Mark Goddard authored
      Including tasks has a performance penalty when compared with importing
      tasks. If the include has a condition associated with it, then the
      overhead of the include may be lower than the overhead of skipping all
      imported tasks. In the case of the check-containers.yml include, the
      included file only has a single task, so the overhead of skipping this
      task will not be greater than the overhead of the task import. It
      therefore makes sense to switch to use import_tasks there.
      
      Partially-Implements: blueprint performance-improvements
      
      Change-Id: I65d911670649960708b9f6a4c110d1a7df1ad8f7
      9702d4c3
  12. Jul 07, 2020
    • Mark Goddard's avatar
      Performance: Run common role in a separate play · 56ae2db7
      Mark Goddard authored
      The common role was previously added as a dependency to all other roles.
      It would set a fact after running on a host to avoid running twice. This
      had the nice effect that deploying any service would automatically pull
      in the common services for that host. When using tags, any services with
      matching tags would also run the common role. This could be both
      surprising and sometimes useful.
      
      When using Ansible at large scale, there is a penalty associated with
      executing a task against a large number of hosts, even if it is skipped.
      The common role introduces some overhead, just in determining that it
      has already run.
      
      This change extracts the common role into a separate play, and removes
      the dependency on it from all other roles. New groups have been added
      for cron, fluentd, and kolla-toolbox, similar to other services. This
      changes the behaviour in the following ways:
      
      * The common role is now run for all hosts at the beginning, rather than
        prior to their first enabled service
      * Hosts must be in the necessary group for each of the common services
        in order to have that service deployed. This is mostly to avoid
        deploying on localhost or the deployment host
      * If tags are specified for another service e.g. nova, the common role
        will *not* automatically run for matching hosts. The common tag must
        be specified explicitly
      
      The last of these is probably the largest behaviour change. While it
      would be possible to determine which hosts should automatically run the
      common role, it would be quite complex, and would introduce some
      overhead that would probably negate the benefit of splitting out the
      common role.
      
      Partially-Implements: blueprint performance-improvements
      
      Change-Id: I6a4676bf6efeebc61383ec7a406db07c7a868b2a
      56ae2db7
  13. Jun 20, 2020
  14. Jun 19, 2020
  15. May 23, 2020
    • Doug Szumski's avatar
      Switch to Monasca API for logs · b39a0f80
      Doug Szumski authored
      The Monasca Log API has been removed and in this change we switch
      to using the unified API. If dedicated log APIs are required then
      this can be supported through configuration. Out of the box the
      Monasca API is used for both logs and metrics which is envisaged to
      work for most use cases.
      
      In order to use the unified API for logs, we need to disable the
      legacy Kafka client. We also rename the Monasca API config file
      to remove a warning about using the old style name.
      
      Depends-On: https://review.opendev.org/#/c/728638
      Change-Id: I9b6bf5b6690f4b4b3445e7d15a40e45dd42d2e84
      b39a0f80
  16. Apr 26, 2020
    • Radosław Piliszek's avatar
      Fix haproxy restarting twice per Ansible run · 04effaa9
      Radosław Piliszek authored
      Since haproxy is orchestrated via site.yml in a single play,
      it does not need flushing handlers as handlers run will
      happen at the end of this play.
      
      Change-Id: Ia3743575da707325be93c39b4a2bcae9211cacb2
      Related-Bug: #1864810
      Closes-Bug: #1875228
      04effaa9
    • Radosław Piliszek's avatar
      Remove redundant listen on haproxy handler · 98e86ea6
      Radosław Piliszek authored
      Follow-up on [1] "Avoid multiple haproxy restarts after
      reconfiguration".
      
      There is no need to duplicate handler name in listen.
      The issue was because we had two handlers with the same
      name in the same environment.
      This causes Ansible not to mark handler as already run.
      
      [1] https://review.opendev.org/708385
      
      Change-Id: I5425a8037b6860ef71bce59becff8dfe5b601d4c
      Related-Bug: #1864810
      98e86ea6
  17. Apr 21, 2020
    • Christian Berendt's avatar
      Avoid multiple haproxy restarts after reconfiguration · 1efe0fe3
      Christian Berendt authored
      The haproxy role and the site.yml file calls the
      haproxy-config role to provide configuration for individual
      services.
      
      If the configuration within a service changes, the haproxy
      container is restarted.
      
      If the configuration in n services changes, there will be n
      restarts. This is not necessary, a restart at the end is
      sufficient.
      
      By removing the handler from the haproxy-config role and
      using the listen parameter in the handler of the haproxy role,
      the handler is executed only once.
      
      Change-Id: I535fe67579fb748093bb4b30a6bd31b81e021a1b
      Closes-Bug: #1864810
      1efe0fe3
  18. Apr 14, 2020
    • James Kirsch's avatar
      Refactor copy certificates task · 4d155d69
      James Kirsch authored
      Refactor service configuration to use the copy certificates task. This
      reduces code duplication and simplifies implementing encrypting backend
      HAProxy traffic for individual services.
      
      Change-Id: I0474324b60a5f792ef5210ab336639edf7a8cd9e
      4d155d69
  19. Apr 09, 2020
    • Dincer Celik's avatar
      Introduce /etc/timezone to Debian/Ubuntu containers · 4b5df0d8
      Dincer Celik authored
      Some services look for /etc/timezone on Debian/Ubuntu, so we should
      introduce it to the containers.
      
      In addition, added prechecks for /etc/localtime and /etc/timezone.
      
      Closes-Bug: #1821592
      Change-Id: I9fef14643d1bcc7eee9547eb87fa1fb436d8a6b3
      4b5df0d8
    • James Kirsch's avatar
      Add support for encrypting backend Keystone HAProxy traffic · b475643c
      James Kirsch authored
      This patch introduces an optional backend encryption for Keystone
      service. When used in conjunction with enabling TLS for service API
      endpoints, network communcation will be encrypted end to end, from
      client through HAProxy to the Keystone service.
      
      Change-Id: I6351147ddaff8b2ae629179a9bc3bae2ebac9519
      Partially-Implements: blueprint add-ssl-internal-network
      b475643c
  20. Apr 08, 2020
    • Mark Goddard's avatar
      Remove support for CentOS 7 · f4e20a1f
      Mark Goddard authored
      CentOS 8 support is now fairly complete - time to drop CentOS 7.
      
      Partially-Implements: blueprint centos-rhel-8
      
      Change-Id: I940b1d3eceb98e16fa366c243672f588b1412d70
      f4e20a1f
    • Mark Goddard's avatar
      Perform host configuration during upgrade · 1d70f509
      Mark Goddard authored
      This is a follow up to I001defc75d1f1e6caa9b1e11246abc6ce17c775b. To
      maintain previous behaviour, and ensure we catch any host configuration
      changes, we should perform host configuration during upgrade.
      
      Change-Id: I79fcbf1efb02b7187406d3c3fccea6f200bcea69
      Related-Bug: #1860161
      1d70f509
  21. Apr 02, 2020
    • Mark Goddard's avatar
      Separate per-service host configuration tasks · fdea19a3
      Mark Goddard authored
      Currently there are a few services that perform host configuration
      tasks. This is done in config.yml. This means that these changes are
      performed during 'kolla-ansible genconfig', when we might expect not to
      be making any changes to the remote system.
      
      This change separates out these host configuration tasks into a
      config-host.yml file, which is included directly from deploy.yml.
      
      One change in behaviour is that this prevents these tasks from running
      during an upgrade or genconfig. This is probably what we want, but we
      should be careful when any of these host configuration tasks are
      changed, to ensure they are applied during an upgrade if necessary.
      
      Change-Id: I001defc75d1f1e6caa9b1e11246abc6ce17c775b
      Closes-Bug: #1860161
      fdea19a3
  22. Mar 25, 2020
    • Mark Goddard's avatar
      Fix HAProxy prechecks during scale-out with limit · f3350d4e
      Mark Goddard authored
      Deploy HAProxy on one or more servers. Add another server to the
      inventory in the haproxy group, and run the following:
      
      kolla-ansible prechecks --limit <new host>
      
      The following task will fail:
      
          TASK [haproxy : Checking if kolla_internal_vip_address and
          kolla_external_vip_address are not pingable from any node]
      
      This happens because ansible does not execute on hosts where
      haproxy/keepalived is running, and therefore does not know that the VIP
      should be active.
      
      This change skips VIP prechecks when not all HAProxy hosts are in the
      play.
      
      Closes-Bug: #1868986
      
      Change-Id: Ifbc73806b768f76f803ab01c115a9e5c2e2492ac
      f3350d4e
  23. Mar 10, 2020
    • Mark Goddard's avatar
      Fix HAProxy monitor VIP precheck · 93a4dcc1
      Mark Goddard authored
      If haproxy is running somewhere in the cluster and listening on the VIP,
      but not running locally, then the following precheck may fail:
      
         TASK [haproxy : Checking free port for HAProxy monitor (vip interface)]
      
         msg: Timeout when waiting for 192.0.2.10:61313 to stop.
      
      This change fixes the issue by skipping the check if HAProxy is running
      on any host.
      
      Change-Id: I831eb2f700ef3fcf65b7e08382c3b4fcc4ce8d8d
      Closes-Bug: #1866617
      93a4dcc1
  24. Mar 02, 2020
  25. Feb 28, 2020
    • Mark Goddard's avatar
      Add Ansible group check to prechecks · 49fb55f1
      Mark Goddard authored
      We assume that all groups are present in the inventory, and quite obtuse
      errors can result if any are not.
      
      This change adds a precheck that checks for the presence of all expected
      groups in the inventory for each service. It also introduces a common
      service-precheck role that we can use for other common prechecks.
      
      Change-Id: Ia0af1e7df4fff7f07cd6530e5b017db8fba530b3
      Partially-Implements: blueprint improve-prechecks
      49fb55f1
  26. Feb 11, 2020
  27. Jan 28, 2020
    • Mark Goddard's avatar
      CentOS 8: Deploy CentOS 8 containers · 3b24e566
      Mark Goddard authored
      * HAProxy is now 1.8 in CentOS 8
      * Support python3 in baremetal role
      * Remove support for environments without python2 installed (this could
        not have worked since we gather facts before this point)
      
      Workarounds:
      
      * Using CentOS 7 yum repo for Docker, with module_hotfixes
      
      Change-Id: I30bd3d58f6224ad4c9575ba66c74deabe6895cc4
      Partially-Implements: blueprint centos-rhel-8
      3b24e566
  28. Jan 17, 2020
  29. Jan 13, 2020
  30. Jan 10, 2020
    • Mark Goddard's avatar
      CentOS 8: Support variable image tag suffix · 9755c924
      Mark Goddard authored
      For the CentOS 7 to 8 transition, we will have a period where both
      CentOS 7 and 8 images are available. We differentiate these images via a
      tag - the CentOS 8 images will have a tag of train-centos8 (or
      master-centos8 temporarily).
      
      To achieve this, and maintain backwards compatibility for the
      openstack_release variable, we introduce a new 'openstack_tag' variable.
      This variable is based on openstack_release, but has a suffix of
      'openstack_tag_suffix', which is empty except on CentOS 8 where it has a
      value of '-centos8'.
      
      Change-Id: I12ce4661afb3c255136cdc1aabe7cbd25560d625
      Partially-Implements: blueprint centos-rhel-8
      9755c924
  31. Dec 10, 2019
    • Pierre Riteau's avatar
      Template custom HAProxy service configuration · 49f33428
      Pierre Riteau authored
      Change Id84e3b6e62e544582d6917047534e846e026798d added support for
      custom HAProxy service config using a plain copy of files in services.d.
      
      Use a template action instead of a copy so that we can use variables and
      iterate over group of hosts.
      
      Change-Id: I1f07785932de4e4540422bd18af95241f05a67bf
      49f33428
  32. Nov 22, 2019
    • Michal Nasiadka's avatar
      Change local_action to delegate_to: localhost · 10099311
      Michal Nasiadka authored
      As part of the effort to implement Ansible code linting in CI
      (using ansible-lint) - we need to implement recommendations from
      ansible-lint output [1].
      
      One of them is to stop using local_action in favor of delegate_to -
      to increase readability and and match the style of typical ansible
      tasks.
      
      [1]: https://review.opendev.org/694779/
      
      Partially implements: blueprint ansible-lint
      
      Change-Id: I46c259ddad5a6aaf9c7301e6c44cd8a1d5c457d3
      10099311
  33. Nov 14, 2019
  34. Nov 11, 2019
Loading