]> review.fuel-infra Code Review - openstack-build/heat-build.git/commitdiff
Don't use uuidgen in install.sh
authorTomas Sedovic <tomas@sedovic.cz>
Fri, 27 Jul 2012 12:37:17 +0000 (14:37 +0200)
committerTomas Sedovic <tomas@sedovic.cz>
Fri, 27 Jul 2012 12:37:17 +0000 (14:37 +0200)
uuidgen is not present in Ubuntu. This simply reads 16 bytes from
/dev/random and stores their hex representation.

Change-Id: If1152242b024218f20bd4c787e03836f0d5f49cf
Signed-off-by: Tomas Sedovic <tomas@sedovic.cz>
install.sh

index 946198b2bbae58a7a1c9c64d7a4c5cf44d6bcca0..5af037946bf4cdc193fa1cb7f79874aca968c0b5 100755 (executable)
@@ -21,7 +21,7 @@ do
         echo "not copying over $CONF_DIR/$f"
         diff -u $CONF_DIR/$f $f
     elif [ $f = 'heat-engine.conf' ]; then
-       cat $f | sed s/%ENCRYPTION_KEY%/`/bin/uuidgen`/ > $CONF_DIR/$f
+       cat $f | sed s/%ENCRYPTION_KEY%/`hexdump -n 16 -v -e '/1 "%02x"' /dev/random`/ > $CONF_DIR/$f
     else
         cp $f $CONF_DIR
     fi