[OpenStack-Infra] How can I get the each node's IP address?

Jeremy Stanley fungi at yuggoth.org
Wed Jun 20 12:47:49 UTC 2018


On 2018-06-20 17:16:52 +0900 (+0900), Rikimaru Honjo wrote:
> I installed Zuul v3 and Nodepool in my environment.
> 
> In the old Nodepool, I could get sub node's IP address from
> /etc/nodepool/sub_nodes. But, this file has been removed.
> 
> How can I get each node's IP address when using multiple nodes in
> my job?
> 
> I'd like to use Controller node's IP address for Compute nodes. I
> read the following document. But I couldn't find the describe
> about my question. https://docs.openstack.org/infra/zuul/

The official URL for Zuul's documentation these days is
https://zuul-ci.org/docs/ (both URLs serve the same content for now
though) and the relevant section is
https://zuul-ci.org/docs/zuul/user/jobs.html?highlight=inventory#job-variables

Confusion is understandable as the documentation doesn't dive into
the particular variables Ansible supplies and isn't written as a
guide for migrating from Zuul v2 to v3. That information which used
to be written to /etc/nodepool can now be inferred from the Ansible
inventory and is exposed as host vars for use in jobs. As an
example, here's how the OpenStack community recreated the old Zuul
v2 /etc/nodepool files with Ansible in their Zuul v3 deployment for
transitional purposes:

https://git.openstack.org/cgit/openstack-infra/openstack-zuul-jobs/tree/playbooks/legacy/pre.yaml?id=842f241#n8

Of course, in Zuul v3 you no longer need to stash these values in
files on the nodes because you can simply reference the variables
directly in your job definitions.

Also, there is a specific discussion list for Zuul these days, you
might prefer to use in the future:

http://lists.zuul-ci.org/cgi-bin/mailman/listinfo/zuul-discuss

-- 
Jeremy Stanley
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 963 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack-infra/attachments/20180620/aae36382/attachment-0001.sig>


More information about the OpenStack-Infra mailing list