1
0
mirror of https://github.com/rancher/os.git synced 2025-08-01 23:17:50 +00:00

Check if os-release exists first

This commit is contained in:
Darren Shepherd 2015-04-15 23:03:49 -07:00
parent 6bb6fb0eec
commit 61b5525d5b

View File

@ -76,7 +76,7 @@ if ! grep -q '^UseDNS no' /etc/ssh/sshd_config; then
fi
ID_TYPE="busybox"
if grep -q 'ID_LIKE=' /etc/os-release; then
if [ -e /etc/os-release ] && grep -q 'ID_LIKE=' /etc/os-release; then
ID_TYPE=$(grep 'ID_LIKE=' /etc/os-release | cut -d'=' -f2)
fi