mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
Update ubuntu.sh
This commit is contained in:
@@ -26,9 +26,21 @@ apt install -y libncurses5
|
||||
apt install -y libncurses5-dev
|
||||
apt install -y software-properties-common
|
||||
|
||||
apt install -y locate
|
||||
locale-gen en_US.UTF-8
|
||||
localedef -v -c -i en_US -f UTF-8 en_US.UTF-8
|
||||
# choose lang cmd
|
||||
# dpkg-reconfigure --frontend=noninteractive locales
|
||||
# dpkg-reconfigure locales
|
||||
if [ ! -f /usr/sbin/locale-gen ];then
|
||||
apt install -y locales
|
||||
sed -i '/en_US.UTF-8/s/^# //g' /etc/locale.gen
|
||||
locale-gen en_US.UTF-8
|
||||
locale-gen zh_CN.UTF-8
|
||||
localedef -v -c -i en_US -f UTF-8 en_US.UTF-8 > /dev/null 2>&1
|
||||
update-locale LANG=en_US.UTF-8
|
||||
else
|
||||
locale-gen en_US.UTF-8
|
||||
locale-gen zh_CN.UTF-8
|
||||
localedef -v -c -i en_US -f UTF-8 en_US.UTF-8 > /dev/null 2>&1
|
||||
fi
|
||||
|
||||
SSH_PORT=`netstat -ntpl|grep sshd|grep -v grep | sed -n "1,1p" | awk '{print $4}' | awk -F : '{print $2}'`
|
||||
if [ "$SSH_PORT" == "" ];then
|
||||
|
||||
Reference in New Issue
Block a user