[libvirt] [jenkins-ci PATCH 1/3] guests: Configure Jenkins agent based on secret availability
Pavel Hrdina
phrdina at redhat.com
Wed Mar 21 15:12:07 UTC 2018
On Wed, Mar 21, 2018 at 04:08:26PM +0100, Andrea Bolognani wrote:
> On Wed, 2018-03-21 at 15:52 +0100, Pavel Hrdina wrote:
> > > - name: Enable Jenkins agent
> > > @@ -39,4 +45,5 @@
> > > enabled: yes
> > > daemon_reload: yes
> > > when:
> > > + - jenkins_secret is defined
> > > - ansible_service_mgr == 'systemd'
> >
> > Would it be possible to create a group of tasks that should be run
> > only if "jenkins_secret is defined" and guard the whole group with
> > that check?
>
> We could use blocks:
>
> http://docs.ansible.com/ansible/latest/playbooks_blocks.html
>
> However, we're not using that feature anywhere and we might want
> to use the 'name' keyword introduced in 2.3 along with it, so I
> would skip this change for now and apply it more widely as part
> of the port to Ansible 2.4.
Works for me.
Reviewed-by: Pavel Hrdina <phrdina at redhat.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20180321/7f359e48/attachment-0001.sig>
More information about the libvir-list
mailing list