Commit Graph

99 Commits

Author SHA1 Message Date
OpenDev Sysadmins 033de77919 OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:33:26 +00:00
Ian Wienand 85ce66c25e Replace openstack.org git:// URLs with https://
This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.

This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.

This update should result in no functional change.

For more information see the thread at

 http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html

Change-Id: I73cbe077a6d0e60bb88f65adf9058f30145a5693
2019-03-24 20:34:56 +00:00
OpenStack Proposal Bot 45223561f0 Updated from OpenStack Ansible Tests
Change-Id: I5aa1bba4686b6415ec74e2ee66e3326b762da2a4
2018-09-13 11:12:25 +00:00
huang.zhiping 06db6d6b54 import zuul job settings from project-config
This is a mechanically generated patch to complete step 1 of moving
the zuul job settings out of project-config and into each project
repository.

Because there will be a separate patch on each branch, the branch
specifiers for branch-specific jobs have been removed.

Because this patch is generated by a script, there may be some
cosmetic changes to the layout of the YAML file(s) as the contents are
normalized.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I864831c16e5a1128295b035eebce3c1d506dfcfe
Story: #2002586
Task: #24319
2018-08-21 13:26:57 +00:00
James E. Blair d545c5df90 Zuul: Remove project name
Zuul no longer requires the project-name for in-repo configuration.
Omitting it makes forking or renaming projects easier.

Change-Id: I9886f5478781819e2823e964b5ac523b09b865b2
2018-01-28 06:22:31 -08:00
Jesse Pretorius 94437771fe Used cached git sources and enable depends-on
Many, many patches have gone into the master branch to
enable the use of depends-on for role tests and to make
use of the git clones put into place by zuul. This patch
ensures that this functionality is now available for this
branch too.

The primary benefit for doing this would be to make use
of the cached git clones provided by zuul to improve test
reliability.

The secondary benefit would be to have the ability to
use depends-on to test patches together.

However, this will come at the cost of requiring a tox
configuration change, and the implementation of the
tests/tests-repo-clone.sh and run_tests.sh scripts
across all repositories.

Change-Id: Iec5c29b677e662f7e17de254f4c4676b5ba7c715
Depends-On: Ia806f19e00703c53f03a2420dbac1da4ba68db6c
2017-11-06 18:22:07 +00:00
Jesse Pretorius c903f6c97c Initial OSA zuul v3 role jobs
This patch implements an initial set of jobs intended to match
the current job execution method. It does not intend to improve
how the jobs are executed - only to replicate what is currently
in openstack-infra/openstack-zuul-jobs and provide the platform
to iterate on.

Change-Id: I5d2f87d6ee3b10f83affcd730e3d28ae18f7af94
2017-10-31 12:36:06 +00:00
OpenStack Proposal Bot 7d2096f74b Updated from OpenStack Ansible Tests
Change-Id: Ia26cdfc380e74cb8e24ee0dac93a2a020a291c34
2017-08-25 11:27:41 +00:00
Jenkins b089d5c25c Merge "Ensure that policy file has correct group/mode" into stable/ocata 2017-06-06 17:11:28 +00:00
Jesse Pretorius d1e4fb9317 Use command instead of debug for handlers
Due to the debug message plugin the handler restart
messages show at the end of the playbook execution
which is a little confusing. Using debug also
requires setting changed_when to true which is a
little extra bit of code which we do not have to
carry.

Instead we use the command module which is simple,
works and less wordy.

Change-Id: I3562ef542ab4c87cd6bac82d916e5696149c8a6b
(cherry picked from commit 32ec0260d2)
2017-05-25 09:35:39 +00:00
Jesse Pretorius 1861937c8e Ensure that policy file has correct group/mode
When the policy file is copied from the templated
file to the active file, it loses its group/mode
settings. This patch ensures that they are properly
replicated during the copy.

Change-Id: I3fdd5d0122dec93a95c47b1f473b74eba11d6f26
(cherry picked from commit ffd26a061b)
2017-05-25 09:33:55 +00:00
Jenkins f8d9bc6f8e Merge "Perform an atomic policy file change" into stable/ocata 2017-05-16 18:16:30 +00:00
Jenkins 40061e1bc9 Merge "Reduce init restart/kill times" into stable/ocata 2017-05-15 22:11:24 +00:00
Jesse Pretorius 4fe36c961d Perform an atomic policy file change
The policy.json file is currently read continually by the
services and is not only read on service start. We therefore
cannot template directly to the file read by the service
(if the service is already running) because the new policies
may not be valid until the service restarts. This is
particularly important during a major upgrade. We therefore
only put the policy file in place after the service restart.

This patch also tidies up the handlers and some of the install
tasks to simplify them and reduce the tasks/code a little.

Change-Id: I8ece1f91db9177f30623f09036e75794d607e17e
(cherry picked from commit e1f0e4cb0c)
2017-05-15 15:52:56 +00:00
Rick Box d53c32af4d Fix for lookup and get_url occuring in different places
We use an SSH bastion host which we do our deployment through. The
deployment host doesn't have direct access to the same network as the
host. As a result the venv local checksum lookup fails.

I have described this here:

https://bugs.launchpad.net/openstack-ansible/+bug/1689283

This is a simple fix for this problem, assuming everything is good it
will need repeating in multiple places in the code base.

Change-Id: Iae75d5fbaa3f8f74f69574b51dbae84948b8dcb6
(cherry picked from commit 4fbbb8096d)
2017-05-10 14:48:36 +00:00
Jesse Pretorius 8214ccfe17 Use package module to install distro packages
Consolidate distro package install tasks into a
single task using the package module and pass
the package list into the name instead of using
a with_items loop.

The minimum Ansible version is raised to 2.2 due to a
known bug [1] in Ansible's apt module which does not
update the cache properly if the cache update and the
install are combined in a single task.

[1] https://github.com/ansible/ansible-modules-core/issues/1497

Change-Id: Id00e704fd89f5dc40a143a9567c859ba78b76668
(cherry picked from commit f97d970fdc)
2017-05-04 06:31:58 +00:00
Jesse Pretorius efc2c191af Reduce init restart/kill times
The systemd unit 'TimeoutSec' value which controls the time
between sending a SIGTERM signal and a SIGKILL signal when
stopping or restarting the service has been reduced from 300
seconds to 120 seconds. This provides 2 minutes for long-lived
sessions to drain while preventing new ones from starting
before a restart or a stop.

The 'RestartSec' value which controls the time between the
service stop and start when restarting has been reduced from
150 seconds to 2 seconds to make the restart happen faster.

These values can be adjusted by using the *_init_config_overrides
variables which use the config_template task to change template
defaults.

Change-Id: Ia10703ca1cfa5afd1dec09a52f1b981711796e33
(cherry picked from commit 5c7c223ab8)
2017-05-03 14:13:26 +01:00
Kevin Carter dda6ec468a Ensure the components are isolated from the system
This creates a specific slice which all OpenStack services will operate
from. By creating an independent slice these components will be governed
away from the system slice allowing us to better optimise resource
consumption.

See the following for more information on slices:

* https://www.freedesktop.org/software/systemd/man/systemd.slice.html

See for following for more information on resource controls:

* https://www.freedesktop.org/software/systemd/man/systemd.resource-control.html

Tools like ``systemd-cgtop`` and ``systemd-cgls`` will now give us
insight into specific processes, process groups, and resouce consumption
in ways that we've not had access to before. To enable some of this reporting
the accounting options have been added to the [Service] section of the unit
file.

Change-Id: Idac3056145b92adcd0b5b328296c59b71bf28441
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
(cherry picked from commit bdc17256d2)
2017-04-26 15:22:01 +00:00
Andy McCrae b4a7dd32aa Fix gitreview and tox requirements to use stable/ocata
Change-Id: I128d94c731939b0d6b2ccdfd7095830f602ee687
2017-02-09 13:46:01 +00:00
Jesse Pretorius d8969d76a3 Update repo for stable/ocata
Change-Id: I84ab2a146c3cb26de510c6a901bfd9c37f585fb7
2017-02-08 11:08:13 +00:00
Cao Xuan Hoang 48412b6941 Use https instead of http for git.openstack.org
Trivialfix

Change-Id: Ie6a1ec3cad1ff192535d054c0ce3cf58800ab651
2017-02-06 17:20:18 +07:00
Jean-Philippe Evrard 3b6300f3ce Phase out trusty and use systemd
We don't support trusty in master anymore, so this makes sures the
support of upstart is phased out.

Whenever possible, we use the systemd module instead, that reduces the
amount of tasks.

Change-Id: I50d377ce6c5e80386954fd551e566c55f57c5a3a
Signed-off-by: Jean-Philippe Evrard <jean-philippe.evrard@rackspace.co.uk>
2017-01-20 12:53:06 +00:00
Logan V 074ae8281b Clean up developer mode logic
Fixes the ability to deploy a venv in cases where:
1) developer_mode is not enabled
2) A cached venv is not downloaded from the repo server

Additional cleanup to the developer_mode venv deployment
logic is implemented by adding a *_venv_download var
which is used to decouple developer_mode from the
cached venv extraction process so that a deployer
can force venv builds in-place (disable cached
venv usage) without enabling developer mode
constraints.

Change-Id: I8bb1ff09d676ce3d2faa2baee385695bffb2db59
2017-01-13 19:52:41 -06:00
Major Hayden 549d009f8d Update and clean up run_tests.sh
The run_tests.sh script fails when it is run multiple times on CentOS.
The `bindep` run returns an empty list of packages and then `yum`
exits with an error since no packages were provided to install.

This patch checks the length of the `bindep` output and skips the `yum`
installation when the package list is empty.

The patch also cleans up some of the old cruft left over from previous
scripts and avoids repetition.

Change-Id: I2d998eec183df1294812f1f0ba032f4dbac925a8
Signed-off-by: Major Hayden <major@mhtx.net>
2017-01-06 16:53:29 +00:00
ZhongShengping 4161ba9381 Remove pki support
Change-Id: Ib579885209f447b501fcb338da4d9321c0aa4498
Implements: blueprint remove-pki
2017-01-04 07:54:48 +00:00
gecong1973 8aa2114d59 Delete deprecated Hacking in tox.ini
Some hacking have been removed,so we can delete them.
More details:
     https://github.com/openstack-dev/hacking/blob/master/setup.cfg

Change-Id: Id1a105be2b8cfa7501c1058ee7d695551b485dfe
2016-12-04 10:20:41 +08:00
OpenStack Proposal Bot 704861086e Updated from global requirements
Change-Id: I996dd0d9f6a6f4f4c70779fea05ab9c2e28d9f89
2016-12-02 05:10:42 +00:00
Jean-Philippe Evrard 1143e484db Point roles docs bugs to openstack-ansible LP
Currently when clicking on the small bug in the roles'
docs, we land on openstack-manuals launchpad.

This should solve it.

Change-Id: Icd1b37214a66ed17db255a3dee93575f57815645
2016-12-01 14:51:31 +00:00
Jenkins 441d7f2dfb Merge "Clean up unused vars" 2016-11-29 10:00:57 +00:00
Flavio Percoco d4374560e5 Show team and repo badges on README
This patch adds the team's and repository's badges to the README file.
The motivation behind this is to communicate the project status and
features at first glance.

For more information about this effort, please read this email thread:

http://lists.openstack.org/pipermail/openstack-dev/2016-October/105562.html

To see an example of how this would look like check:

https://gist.github.com/7da10610895ba214bf71dd77409331a8

Change-Id: I28e94e28408097320c196bbfcf8a0006661fedee
2016-11-25 16:29:53 +01:00
Pedro Perez e3bfd2848f Clean up unused vars
Change-Id: I72b791bdad0ffb7c928eb4c627094968d179173d
2016-11-23 21:10:32 +01:00
Jenkins 9482232df7 Merge "update naming conventions for secret vars" 2016-11-21 04:08:55 +00:00
Pedro Perez be53f8eca8 update naming conventions for secret vars
Change-Id: I523b5f1ae56c1ff19ca6bd95e3e0e7f00e282c71
2016-11-18 16:42:48 +01:00
Jesse Pretorius f069211ece Reinitialize venv upon install
Reinitializes (copies python, etc binaries) into the venv when
dropping a new venv into place. This is needed because the Python
binary packaged with the venv may not match the Python running on
the host it is being installed to. (ie. in the case of a Xenial
repo container and a Trusty target host.)

Change-Id: Ie87ebd7aefaf7117e8fbd9711e887233eec8ff1c
Partial-Bug: #1637509
2016-11-16 09:14:16 +00:00
Pedro Perez abf382bb68 Add rabbit_port to cloudkitty.conf template
Change-Id: I0dc824ccd4e46d9ab76d0908a1f28f3e9b1fe927
Closes-Bug: #1641695
2016-11-14 21:10:36 +01:00
Jesse Pretorius f7be6befee Remove join filter from pip module tasks
Ansible 2.2 now treats the 'name' argument for the pip module
as a list, removing the need for us to implement the join
filter to optimise the install execution.

Change-Id: I76bdcc75bf5bbe0c766409d43648dcf567a9de6f
2016-11-09 21:32:33 +00:00
Jesse Pretorius da1f3eb15b Use updated get_url module checksum functionality
Starting in Ansible 2.0, the get_url [1] module provides the
ability for a checksum to be provided to the get_url module
which will be verified against the local destination file
and the task skipped if it matches.

[1] http://docs.ansible.com/ansible/get_url_module.html

This patch implements the use of this functionality.

The ability to ignore a venv download failure is also removed
as this is not necessary or desirable. It is better for the
download to fail and the playbook execution to stop immediately
so that the failure point is exposed.

Change-Id: Ib457a9c68f4cf627b0496574cda628ed304692c1
2016-11-07 17:46:09 +00:00
Jesse Pretorius 0997138c0e Fix linting issues for ansible-lint 3.4.1
Preparing this role for the ansible-lint version bump

Change-Id: I36f5b951b5dcaa52e35079f32e98f2aae94e2df0
2016-11-07 09:57:08 +00:00
Jean-Philippe Evrard 0dd25b362d Remove ansible<2.2 apt cache hack
Now ansible apt module correctly behaves, so it's time
to deprecate these cruft tasks for apt.

Change-Id: Ia32c1496ca818582a287ec70569a63ae78e1e2b6
2016-11-03 23:34:30 +00:00
Jenkins 774f1d03dc Merge "Simplify pip options/constraints mechanism" 2016-11-02 17:40:53 +00:00
OpenStack Proposal Bot 20575552fd Updated from global requirements
Change-Id: Ica8bdaf26b8cbccd9e854384a0eb69057c26a06c
2016-11-02 15:37:36 +00:00
Jesse Pretorius 2bdb5c0131 Simplify pip options/constraints mechanism
The current constraints generation for the
installation involves multiple tasks and multiple
variables.

Using multiple tasks extends the installation time
unnecessarily and the additional variables are
unnecessary.

This patch aims to simplify the mechanism and
hopes to speed it up a little.

Change-Id: I018e2d345912722a6c5e6fbbbb5afd424807f3a4
2016-11-02 13:16:08 +00:00
Kevin Carter b13646c716 Remove deprecated ansible_ssh_host variable
This changes 'ansible_ssh_host' to 'ansible_host'. The 'ansible_ssh_host'
variable has been deprecated as noted here: [0].

[0] - http://docs.ansible.com/ansible/intro_inventory.html#hosts-and-groups

Change-Id: I667cb70dd0fef80699cc9f6cb44091cddaaaa57b
Related-Bug: #1636606
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-10-25 19:41:55 +00:00
Jesse Pretorius 115b9d789e Use upper constraints for all tox targets
With the implementation of https://review.openstack.org/388087 all
tox targets may now use upper constraints.

Change-Id: I60b86d9c6853f6f512ce0e658a68f85b898fac27
2016-10-19 07:42:08 +01:00
Kevin Carter e96f805c6f Remove 'ignore_errors: true' in favor of 'failed_when: false'
This change removes the use of 'ignore_errors: true' because it causes deployers
to see red output and a stacktrace, which traditionally means something is broken,
even when the failure is known to have a fall back option or be intentional. This
conversion will provide a generally cleaner interface.

It should be noted that the 'failed' filter will still function normally. Tasks
with the 'failed_when: false' option will still be marked as 'failed' in any
registered variable. This change simply makes the output look cleaner.

Change-Id: I9b2a7c6ca8ea0f69ca7defc7266c17be224b4b9e
Closes-Bug: #1633438
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-10-14 16:45:03 -05:00
Andreas Jaeger 5b819e0225 Enable release notes translation
Releasenote translation publishing is being prepared. 'locale_dirs'
needs to be defined in conf.py to generate translated version of the
release notes.

Note that this repository might not get translated release notes - or
no translations at all - but we add the entry here nevertheless to
prepare for it.

Change-Id: Icd8586b171111ec38976fb032a2e37e29dd7226d
2016-10-06 20:36:21 +02:00
Jesse Pretorius 1d6f47a9a0 Use centralised Ansible test scripts
This patch consumes the centralised Ansible test scripts
implemented in https://review.openstack.org/381853

Change-Id: I1be5cedefff3bdd2fae541bf5383bbad3953eb24
2016-10-05 12:14:01 +01:00
Jesse Pretorius 8c0f6d0676 Remove install_test_packages variable
With https://review.openstack.org/381479 merged, setting this
variable in tox.ini via an extra var is unnecessary.

Change-Id: Ifd97b517c912d8d527bf6b55857795fbc9b0e2bf
2016-10-04 11:40:50 +01:00
Jesse Pretorius f5e7b7f607 Remove dynamic inclusion from inventory-based service setup
As the service setup for upstart/systemd makes use of the inventory,
the dynamic inclusion being forced causes unpredictable behaviour.

This patch removed the forced dynamic inclusion.

Change-Id: Ideefeadb75ba5de9c23f5ad1b57588d7eb03e887
2016-09-30 18:51:52 +01:00
Jesse Pretorius dba2e47fc1 Use dictionary for service group mappings
Change the 'cloudkitty_service_names' from a list to a dictionary mapping
of services, groups that install those services. This brings the
method into line with that used in the os_neutron role in order to
implement a more standardised method.

The init tasks have been updated to run once and loop through this
mapping rather than being included multiple times and re-run against
each host. This may potentially reduce role run times.

Currently the reload of upstart/systemd scripts may not happen if
only one script changes as the task uses a loop with only one result
register. This patch implements handlers to reload upstart/systemd
scripts to ensure that this happens when any one of the scripts
change.

The handler to reload the services now only tries to restart the
service if the host is in the group for the service according to the
service group mapping. This allows us to ensure that handler
failures are no longer ignored and that no execution time is wasted
trying to restart services which do not exist on the host.

Finally:
- Common variables shared by each service's template files have
  been updated to use the service namespaced variables.
- Unused handlers have been removed.
- Unused variables have been removed.

Change-Id: Ieb96fac62906ac9eb387edb450df0c0ca9c0ccb2
2016-09-29 07:24:46 +01:00