
This reverts commit 2614e5fa95aab680fb6f9287831e50c65f76f72c. The repository is actually maintained, the authors merely misunderstood the stackforge namespace retirement maintenance announcements[1] and didn't realize they needed to notify us of that status. Reverting the repository to its former state in preparation for a namespace move in a coming project rename maintenance. [1] http://lists.openstack.org/pipermail/openstack-infra/2015-August/003119.html Change-Id: I6ccdcd8f8a084711c265e42c77b3b4159af27b24
24 lines
507 B
Bash
Executable File
24 lines
507 B
Bash
Executable File
#!/bin/bash
|
|
function mac_address_part() {
|
|
hex_number=$(printf '%02x' $RANDOM)
|
|
number_length=${#hex_number}
|
|
number_start=$(expr $number_length - 2)
|
|
echo ${hex_number:$number_start:2}
|
|
}
|
|
|
|
function mac_address() {
|
|
echo "'00:00:$(mac_address_part):$(mac_address_part):$(mac_address_part):$(mac_address_part)'"
|
|
}
|
|
|
|
machines=''
|
|
for i in `seq $1`; do
|
|
mac=$(mac_address)
|
|
|
|
if [[ -z $machines ]]; then
|
|
machines="${mac}"
|
|
else
|
|
machines="${machines} ${mac}"
|
|
fi
|
|
done
|
|
echo ${machines}
|