[ARVADOS] created: 21f2d53a70dbf6ae04db07e163f4485e3af47478

git at public.curoverse.com git at public.curoverse.com
Thu Aug 20 11:34:41 EDT 2015


        at  21f2d53a70dbf6ae04db07e163f4485e3af47478 (commit)


commit 21f2d53a70dbf6ae04db07e163f4485e3af47478
Author: Ward Vandewege <ward at curoverse.com>
Date:   Thu Aug 20 11:34:17 2015 -0400

    Improve compute node setup script.
    
    closes #6942

diff --git a/doc/install/install-compute-node.html.textile.liquid b/doc/install/install-compute-node.html.textile.liquid
index afde1a8..f648768 100644
--- a/doc/install/install-compute-node.html.textile.liquid
+++ b/doc/install/install-compute-node.html.textile.liquid
@@ -108,7 +108,10 @@ set -e
 if ! test -f /root/node.json ; then
     python - <<EOF
 import arvados, json, socket
-node = arvados.api('v1').nodes().create(body={'hostname': socket.gethostname()}).execute()
+fqdn = socket.getfqdn()
+hostname, _, domain = fqdn.partition('.')
+ip_address = socket.gethostbyname(socket.gethostname())
+node = arvados.api('v1').nodes().create(body={'hostname': hostname, 'domain': domain, 'ip_address': ip_address}).execute()
 with open('/root/node.json', 'w') as node_file:
     json.dump(node, node_file, indent=2)
 EOF
@@ -121,7 +124,7 @@ UUID=`grep \"uuid\" /root/node.json  |cut -f4 -d\"`
 PING_SECRET=`grep \"ping_secret\" /root/node.json  |cut -f4 -d\"`
 
 if ! test -f /etc/cron.d/node_ping ; then
-    echo "*/5 * * * * root /usr/bin/curl -k -d ping_secret=$PING_SECRET https://api/arvados/v1/nodes/$UUID/ping" > /etc/cron.d/node_ping
+    echo "*/5 * * * * root /usr/bin/curl -k -d ping_secret=$PING_SECRET https://$ARVADOS_API_HOST/arvados/v1/nodes/$UUID/ping" > /etc/cron.d/node_ping
 fi
 
 /usr/bin/curl -k -d ping_secret=$PING_SECRET https://api/arvados/v1/nodes/$UUID/ping?ping_secret=$PING_SECRET

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list