This is pretty trivial, but consistency is probably better in this
regard and it does guide you to writing a sentence that is human
parsable, which is the point of it.
Change-Id: Iaab9bb6aec0ad0f1d3cae10364c1f1b37d02801e
This is preparation for a later version of ansbile-lint, which finds
missing names on blocks. This seems a reasonable rule, and the
Ansible manual says [1]
Names for blocks have been available since Ansible 2.3. We recommend
using names in all tasks, within blocks or elsewhere, for better
visibility into the tasks being executed when you run the playbook.
This simply adds a name tag for blocks that are missing it. This
should have no operational change, but allows us to update the linter
in a follow-on change.
[1] https://docs.ansible.com/ansible/latest/user_guide/playbooks_blocks.html
Change-Id: I92ed4616775650aced352bc9088a07e919f1a25f
We should make it easy for users to view console logs by default.
Today, we compress and upload logs and by default apache / nginx will
not properly display them as plain text. This commit changes the
default to not compress, but allows more advanced users to enable this
logic. As mostly likley it also means additional configuration for
your web server.
Change-Id: Ic446db4f85e2098db8fa4568f8c5140ba564e931
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
The upload logs roles can make use of the build logs sharding via their
calls into set-zuul-log-path-fact. Document this.
Change-Id: Ia57fc6a47227657f9fac70074e453cf8d4c16c26
With the arrival of ansible-lint 4, Jinja2 variable expansions must
include spaces before and after the variable name inside the
brackets.
Adjust the new violations accordingly and remove the rule
206 exclusion.
Change-Id: Ib3ff7b0233a5d5cf99772f9c2adc81861cf34ffa
We install zuul via test-requirements, so the zuul files should be in a
directory under the site-packges of the virtualenv that tox installed it
in to. Update the path to point correctly to that location.
Remove the ansible-lint skip tags which should now work because the
library path should be pointing to a location that actually holds the
content.
Change-Id: If2d4b39267c4b9a3102a951143b568f8447af8d9
The file module with recurse goes to the bad place when the content has
a symlink to '.'. Rather than fighting it - just use chmod -R, which
does what we want.
Change-Id: Id3e23e67727d8ac7f29c87d6865b54dc729ccaf4
The 'linters' tox environment was not running on roles, it was only
running on playbooks. This change adds a command to the linters
environment to ensure all roles are linted.
Since these weren't being linted, there were some problems with them.
The first was a warning about usage of the shell module. Both of these
usages seemed appropriate, so this patch adds a skip_ansible_lint tag to
each task that was failing. The second is a warning "no action detected
in task" for zuul modules. This is due to the fact that the linter
cannot find the custom module. One option is to set the ANSIBLE_LIBRARY
path to point to the zuul ansible library directory[1], but the linter
virtualenv does not actually have zuul installed. Instead, we just
disable the linter for the failing tasks.
This also cleans up a comment in the tox file that was referring to a
nonexistent zuul job.
[1] https://github.com/willthames/ansible-review/issues/16
Change-Id: Ie49da9a09733b623bb25c5a4c8aa07eacacf4b33
So that it is possible to debug this role, add a flag which disables
setting no_log on the synchronize task.
Change-Id: Ie433ada5ff6cb15b68f19e8678244af9ce9faa13
Depends-On: https://review.openstack.org/556881
As a relief valve for times of storage pressure on the receiving end,
add a flag that can be set to skip log uploads for sucessful jobs.
It uses the same logic as emit-ara-html.
zuul_site_upload_logs == true (the default) will always upload logs
zuul_site_upload_logs == false will never upload logs
zuul_site_upload_logs == 'failure' will only upload failure logs
Setting this variable should be done in site variables.
Change-Id: I2a55730976520b75dcc98f86f34b7929f9243e62
Fix a few problems noticed when using this in project-config:
* Ignore apt-get warning in configure-mirrors
* All tasks should be named in upload-logs, emit-job-header
* use git_config in mirror-workspace-git-repos
* Ignore git warnings in mirror-workspace-git-repos
Change-Id: Ibcdc8d5a42fb081b5faa0cc89460e4cf88d369ba
There are no playbooks that use the roles in this repo in a way that
would lint them, however running linters in project-config found
numerous issues in these roles. Correct the roles.
Change-Id: I017532c8aed8fd90474052423c7ba2510cf84631
Signed-off-by: Jesse Keating <omgjlk@us.ibm.com>
Make log_path zuul_log_path because log_path is rather generic.
Rename generate-log-url to set-zuul-log-path-fact to make it
clearer what it does.
Change-Id: I91ae1e396b3ef04939edebaeea8e5b16cc50315a
This is so that we can call it in the pre playbook for emitting info.
As part of doing this, use include_role to run it from upload-logs as it
always wants to be used there.
Change-Id: Ibd7d6bdb6275d052bcef2af068882e9b2876ef83
These roles are failing yamllint:
roles/upload-logs/tasks/main.yaml
23:5 error wrong indentation: expected 6 but found 4 (indentation)
roles/bindep/tasks/install.yaml
7:3 error wrong indentation: expected 4 but found 2 (indentation)
Change-Id: I189dd08c4d1c091d1e53ca87d52dbaf3f89ba45f
We can pass in the fileserver, but if you're using upload-logs, you're
going to need it to return data, so move this functionality into the
role.
Change-Id: I987b1060acd3e6d96519010673fd21eba781f162
In change If9ebdc783dcef4f8dea9fa491b40ae49416e5cf1 in zuul uuid was
renamed to build. This must be also reflected here.
Change-Id: I46101d7a9ecc1513647f19d1d377480d5afa9a5d