<div dir="ltr"><div>Hi,</div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Feb 18, 2018 at 10:25 PM, Ian Wienand <span dir="ltr"><<a href="mailto:iwienand@redhat.com" target="_blank">iwienand@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
How should we go about restricting certain image builds to specific<br>
nodepool builder instances?  My immediate issue is with ARM64 image<br>
builds, which I only want to happen on a builder hosted in an ARM64<br>
cloud.<br>
<br>
Currently, the builders go through the image list and check "is the<br>
existing image missing or too old, if so, build" [1].  Additionally,<br>
all builders share a configuration file [2]; so builders don't know<br>
"who they are".<br>
<br></blockquote><div><br></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Why not just split the builder configuration file? I don't see a need to add code</span><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial">to do this.</div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><br></div><br class="gmail-Apple-interchange-newline"> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I'd propose we add an arbitrary tag/match system so that builders can<br>
pickup only those builds they mark themselves capable of building?<br>
<br>
e.g. diskimages would specify required builder tags similar to:<br>
<br>
---<br>
diskimages:<br>
  - name: arm64-ubuntu-xenial<br>
    elements:<br>
      - block-device-efi<br>
      - vm<br>
      - ubuntu-minimal<br>
      ...<br>
    env-vars:<br>
      TMPDIR: /opt/dib_tmp<br>
      DIB_CHECKSUM: '1'<br>
      ...<br>
    builder-requires:<br>
      architecture: arm64<br>
---<br>
<br>
The nodepool.yaml would grow another section similar:<br>
<br>
---<br>
builder-provides:<br>
  architecture: arm64<br>
  something_else_unique_about_<wbr>this_buidler: true<br>
---<br>
<br>
For OpenStack, we would template this section in the config file via<br>
puppet in [2], ensuring above that only our theoretical ARM64 build<br>
machine had that section in it's config.<br>
<br>
The nodepool-buidler build loop can then check that its<br>
builder-provides section has all the tags specified in an image's<br>
"builder-requires" section before deciding to start building.<br>
<br>
Thoughts welcome :)<br>
<br>
-i<br>
<br>
[1] <a href="https://git.openstack.org/cgit/openstack-infra/nodepool/tree/nodepool/builder.py#n607" rel="noreferrer" target="_blank">https://git.openstack.org/<wbr>cgit/openstack-infra/nodepool/<wbr>tree/nodepool/builder.py#n607</a><br>
[2] <a href="https://git.openstack.org/cgit/openstack-infra/project-config/tree/nodepool/nodepool.yaml" rel="noreferrer" target="_blank">https://git.openstack.org/<wbr>cgit/openstack-infra/project-<wbr>config/tree/nodepool/nodepool.<wbr>yaml</a><br>
<br>
______________________________<wbr>_________________<br>
Zuul-discuss mailing list<br>
<a href="mailto:Zuul-discuss@lists.zuul-ci.org">Zuul-discuss@lists.zuul-ci.org</a><br>
<a href="http://lists.zuul-ci.org/cgi-bin/mailman/listinfo/zuul-discuss" rel="noreferrer" target="_blank">http://lists.zuul-ci.org/cgi-<wbr>bin/mailman/listinfo/zuul-<wbr>discuss</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>David Shrewsbury (Shrews)<br></div></div></div>
</div></div>