Compare commits
7 Commits
v2024.03.0
...
develop
Author | SHA1 | Date | |
---|---|---|---|
b3fba8f4ee | |||
e216c0ddbf | |||
ede2142b9f | |||
c9bedc3bf8 | |||
df8872064a | |||
af6c9cfbe6 | |||
73159308d1 |
@ -1 +1 @@
|
|||||||
2024.3.1-stable.1041.8f21313
|
2024.3.13-stable.821.cec5c78
|
||||||
|
@ -11,14 +11,13 @@ main() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Accumulate data to create unique machine id
|
# Accumulate data to create unique machine id
|
||||||
local mac_addresses=$(cat /sys/class/net/*/address | uniq | sort)
|
local random_uuid=$(cat /proc/sys/kernel/random/uuid)
|
||||||
local device_uuid=$(dmidecode | grep UUID)
|
|
||||||
|
|
||||||
# Ensure destination directory
|
# Ensure destination directory
|
||||||
mkdir -p "$(dirname "$machine_id_file")"
|
mkdir -p "$(dirname "$machine_id_file")"
|
||||||
|
|
||||||
# Generate SHA256 hash of data and save it to $machine_id_file
|
# Generate SHA256 hash of data and save it to $machine_id_file
|
||||||
echo "$mac_adresses $device_uuid" | sha256sum | cut -d ' ' -f1 > "$machine_id_file"
|
echo "$random_uuid" | sha256sum | cut -d ' ' -f1 > "$machine_id_file"
|
||||||
}
|
}
|
||||||
|
|
||||||
main
|
main
|
Loading…
x
Reference in New Issue
Block a user