mirror of
https://github.com/PartialVolume/shredos.x86_64.git
synced 2026-02-20 09:35:26 +00:00
Merge pull request #404 from PartialVolume/add-nonet-option
Add kernel command line flags, nonet and shredos_nonet
This commit is contained in:
@@ -13,6 +13,15 @@ ifdown -f -a
|
||||
# Bring up loopback device
|
||||
ifup lo
|
||||
|
||||
# ------------------------------------------------------------
|
||||
# Option: completely disable networking
|
||||
# Kernel cmdline flags: "nonet" or "shredos_nonet"
|
||||
# ------------------------------------------------------------
|
||||
if grep -Eq '(^| )nonet(=| |$)|(^| )shredos_nonet(=| |$)' /proc/cmdline 2>/dev/null; then
|
||||
echo "[INFO] Network disabled via kernel cmdline (nonet/shredos_nonet)."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# delete the existing non populated interfaces file
|
||||
rm /etc/network/interfaces
|
||||
|
||||
|
||||
Reference in New Issue
Block a user