|
|
|
@ -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 |
|
|
|
|