Unfortunately this is failing in the gate, and I have no idea why (it
works locally ...). Add some debugging. Since this is called with a
secret from a post-review only job in the trusted project-config repo,
there's little way to self-test this without committing things :/
Hopefully this sheds some light ...
Change-Id: I7d661f8eefe25d90b5eded309062f32344b3379c
This was just a variable change I missed in
I514fb1285196aae0b49a98f0efc21326730e4179 ; the name of the variable
doesn't need the "rtd_" prefix.
Change-Id: I3774b370920be816235ee3af804f6de92d3ba0f5
What I missed when I layed this out was that you setup a secret like
- secret:
name: rtd_credentials
data:
username: openstackci
password: foo
what you have in the job variables is a dictionary called
"rtd_credentials".
It makes it much simpler to use the role with the secret if it accepts
this variable, rather than having to extract the username/password etc
out of the secret dictionary into separate variables.
Additionally, turn on no_log for the uri calls, to avoid potentially
logging any credentials.
Change-Id: I514fb1285196aae0b49a98f0efc21326730e4179
The old API endpoint is deprecated, so add a role that pings the
webhook as described in [1].
Authentication can happen via a token or username/password combo,
which need to be kept in secrets.
The webhook api has an "id" value which some fiddling suggests is an
incrementing integer each time a webhook endpoint is generated (if you
create, delete, create your webhook via the admin interface, you often
as not get the next value). Unfortunately, it appears you can not
query this in any way automatically; it has to be provided. However,
I do not believe this has to be secret; you can not trigger the
end-point without authentication (either password or token).
This means the generic playbook here will not work any more. Because
secrets are bound to the playbook they are defined within, this role
will need to be called directly. It will be removed in a follow-on.
[1] https://docs.readthedocs.io/en/latest/webhooks.html
Change-Id: I651efdb093df85cea3ab2eaf1a5a9256c87a2ca4