add net-tools install, remove full path to ip command
This commit is contained in:
parent
d1f589a9d8
commit
6160b1d10a
|
@ -71,7 +71,7 @@ sed -i "s|//Unattended-Upgrade::Mail \"\";|Unattended-Upgrade::Mail \"$WEBMASTER
|
|||
DEBIAN_FRONTEND=noninteractive apt-get -y install firewalld --no-install-recommends
|
||||
firewall-cmd --set-default-zone=public
|
||||
# get public interface (e.g. eth0, enp0s10, etc.) then add it to the default (public) zone
|
||||
INTERFACE=$(/usr/bin/ip route get 1.1.1.1 | sed -n 's/.*dev \([^\ ]*\).*/\1/p')
|
||||
INTERFACE=$(ip route get 1.1.1.1 | sed -n 's/.*dev \([^\ ]*\).*/\1/p')
|
||||
firewall-cmd --permanent --zone=public --add-interface=$INTERFACE
|
||||
# ssh should already be enabled by default, just making sure
|
||||
firewall-cmd --permanent --zone=public --add-service=ssh
|
||||
|
@ -111,7 +111,7 @@ sed -i 's|.*MaxRetentionSec=.*|MaxRetentionSec=1week|g' /etc/systemd/journald.co
|
|||
systemctl restart systemd-journald.service
|
||||
|
||||
# install some handy extra packages
|
||||
DEBIAN_FRONTEND=noninteractive apt-get -y install gdu exa pwgen
|
||||
DEBIAN_FRONTEND=noninteractive apt-get -y install gdu exa pwgen net-tools
|
||||
|
||||
# install
|
||||
chmod 750 sbin/*
|
||||
|
|
Loading…
Reference in New Issue
Block a user