Skip to content
Permalink
Browse files

Ensure systemctl is in /usr/bin, Restart sshd

  • Loading branch information...
NEMS Linux
NEMS Linux committed Aug 24, 2019
1 parent 850fb82 commit a3f556339307a63bd71cc6209385a963312cea66
Showing with 9 additions and 0 deletions.
  1. +7 −0 build/003-system
  2. +2 −0 build/030-user
@@ -8,3 +8,10 @@ apt -y install iputils-ping
if [[ ! -e /usr/bin/php ]]; then
apt -y install php
fi

# Ensure systemctl resides at both common locations
if [[ ! -e /usr/bin/systemctl ]]; then
if [[ -e /bin/systemctl ]]; then
ln -s /bin/systemctl /usr/bin/systemctl
fi
fi
@@ -46,6 +46,8 @@ platform=$(/usr/local/bin/nems-info platform)
# Ensure password authentication is enabled (otherwise cannot login to some features on AWS, nor become root)
# It is up to you to ensure 1) you are using strong passwords and 2) you only have YOUR IP address(es) allowed to connect in your firewall
/bin/sed -i -- 's,PasswordAuthentication no,PasswordAuthentication yes,g' /etc/ssh/sshd_config
# Load the new config
/bin/systemctl restart sshd

# Remove sudo message
echo "Defaults lecture = never" > /etc/sudoers.d/privacy

0 comments on commit a3f5563

Please sign in to comment.
You can’t perform that action at this time.