Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Use kern.bootfile instead of cat/grep dmesg to find is this is a dev …

…kernel. Whitespace fixes.
  • Loading branch information...
commit 0688032fe4196de8cd0ec4ba07a57a3240118533 1 parent c25ea27
@ermal ermal authored
View
4 lua_installer
@@ -48,7 +48,7 @@ fi
# Check if host is running on VMware
if [ -f /var/log/dmesg.boot ]; then
- if [ `cat /var/log/dmesg.boot | grep VMware | wc -l` -gt 0 ]; then
+ if [ `cat /var/log/dmesg.boot | /usr/bin/grep VMware | /usr/bin/wc -l` -gt 0 ]; then
echo -n "VMware detected. The installer will make changes to tune this host."
touch /var/IS_VMWARE
sleep 1
@@ -62,7 +62,7 @@ if [ -f /var/log/dmesg.boot ]; then
fi
# Check if host is running on pfSenseDEV
- if [ `cat /var/log/dmesg.boot | grep pfSense_Dev | wc -l` -gt 0 ]; then
+ if [ `/sbin/sysctl -n kern.bootfile | /usr/bin/grep pfSense_Dev | /usr/bin/wc -l` -gt 0 ]; then
echo -n "${product} developer iso detected."
touch /var/pfSenseDEV
sleep 1
View
40 lua_installer_RELENG_2
@@ -48,31 +48,31 @@ fi
# Check if host is running on VMware
if [ -f /var/log/dmesg.boot ]; then
- if [ `cat /var/log/dmesg.boot | grep VMware | wc -l` -gt 0 ]; then
- echo -n "VMware detected. The installer will make changes to tune this host."
+ if [ `cat /var/log/dmesg.boot | /usr/bin/grep VMware | /usr/bin/wc -l` -gt 0 ]; then
+ echo -n "VMware detected. The installer will make changes to tune this host."
touch /var/IS_VMWARE
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo "."
fi
# Check if host is running on pfSenseDEV
- if [ `cat /var/log/dmesg.boot | grep pfSense_Dev.6 | wc -l` -gt 0 ]; then
- echo -n "${product} developer iso detected."
+ if [ `/sbin/sysctl -n kern.bootfile | /usr/bin/grep pfSense_Dev | /usr/bin/wc -l` -gt 0 ]; then
+ echo -n "${product} developer iso detected."
touch /var/pfSenseDEV
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo "."
fi
if [ -f /var/run/dmesg.boot ]; then
View
4 lua_installer_full
@@ -45,7 +45,7 @@ touch /tmp/install-session.sh
# Check if host is running on VMware
if [ -f /var/log/dmesg.boot ]; then
- if [ `cat /var/log/dmesg.boot | grep VMware | wc -l` -gt 0 ]; then
+ if [ `cat /var/log/dmesg.boot | /usr/bin/grep VMware | /usr/bin/wc -l` -gt 0 ]; then
echo -n "VMware detected. The installer will make changes to tune this host."
touch /var/IS_VMWARE
sleep 1
@@ -59,7 +59,7 @@ if [ -f /var/log/dmesg.boot ]; then
fi
# Check if host is running on pfSenseDEV
- if [ `cat /var/log/dmesg.boot | grep pfSense_Dev | wc -l` -gt 0 ]; then
+ if [ `/sbin/sysctl -n kern.bootfile | /usr/bin/grep pfSense_Dev | /usr/bin/wc -l` -gt 0 ]; then
echo -n "${product} developer iso detected."
touch /var/pfSenseDEV
sleep 1
View
42 lua_installer_rescue
@@ -45,31 +45,31 @@ touch /tmp/install-session.sh
# Check if host is running on VMware
if [ -f /var/log/dmesg.boot ]; then
- if [ `cat /var/log/dmesg.boot | grep VMware | wc -l` -gt 0 ]; then
- echo -n "VMware detected. The installer will make changes to tune this host."
+ if [ `cat /var/log/dmesg.boot | /usr/bin/grep VMware | /usr/bin/wc -l` -gt 0 ]; then
+ echo -n "VMware detected. The installer will make changes to tune this host."
touch /var/IS_VMWARE
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo "."
fi
# Check if host is running on pfSenseDEV
- if [ `cat /var/log/dmesg.boot | grep pfSense_Dev.6 | wc -l` -gt 0 ]; then
- echo -n "${product} developer iso detected."
- touch /var/pfSenseDEV
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo -n "."
- sleep 1
- echo "."
+ if [ `/sbin/sysctl -n kern.bootfile | /usr/bin/grep pfSense_Dev | /usr/bin/wc -l` -gt 0 ]; then
+ echo -n "${product} developer iso detected."
+ touch /var/pfSenseDEV
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo -n "."
+ sleep 1
+ echo "."
fi
if [ -f /var/run/dmesg.boot ]; then
Please sign in to comment.
Something went wrong with that request. Please try again.