Add node UUI display macro 69/1569/1
authorJessica Wagantall <jwagantall@linuxfoundation.org>
Wed, 11 Sep 2019 18:13:06 +0000 (11:13 -0700)
committerJessica Wagantall <jwagantall@linuxfoundation.org>
Wed, 11 Sep 2019 18:14:18 +0000 (11:14 -0700)
Add macro to display node's UUID
Add macro to ta-ci-build

Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
Change-Id: I7d6b43c771718c2458ed2405d90998403e8fdf5e

jjb/akraino-templates/akraino-ta-common-macros.yaml
jjb/akraino-templates/akraino-ta-common-templates.yaml

index 51095f5..7006eac 100644 (file)
 ###########
 # BUILDER #
 ###########
+- builder:
+    name: lf-display-node-uuid
+    builders:
+        - shell: |2-
+            echo "---> Node UUID:"
+            curl -s http://169.254.169.254/openstack/latest/meta_data.json | python -c 'import sys, json; data = json.load(sys.stdin); print(data["uuid"])'
+
 - builder:
     name: ta-builder-tox
     builders:
index e1ecc08..123fda6 100644 (file)
           jenkins-ssh-credential: '{jenkins-ssh-credential}'
 
     builders:
+      - lf-display-node-uuid
       - ta-builder-scm:
           git-url: '{git-url}'
           project: 'ta/manifest'