赞
踩
sudo passwd root
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
sudo apt install vim
sudo vim /etc/apt/sources.list
,将里面的内容全删后,配置为清华源,清华源如下:deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
sudo apt-get update
sudo apt-get -f install
sudo apt-get upgrade
sudo vim /usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf
, 把配置改为如下所示[Seat:*]
user-session=ubuntu
greeter-show-manual-login= true
all-guest=false #这个可以 不用配置
执行sudo vim /etc/pam.d/gdm-autologin
注释掉auth required pam_succeed_if.so user != root quiet_success这一行(第三行左右)
执行sudo vim /etc/pam.d/gdm-password
注释掉 auth required pam_succeed_if.so user != root quiet_success这一行(第三行左右)
执行sudo vim /root/.profile
修改配置文件如下
# ~/.profile: executed by Bourne-compatible login shells.
if [ "$BASH" ]; then
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
fi
tty -s && mesg n || true
mesg n || true
reboot
,选择root用户mkdir /home/go
wget https://golang.google.cn/dl/go1.17.8.linux-amd64.tar.gz
sudo tar -zxvf go1.17.8.linux-amd64.tar.gz
mkdir /home/go/goProject
sudo vim /etc/profile
export GOROOT=/home/go/go
export GOPATH=/home/go/goProject
export GOPROXY=https://goproxy.cn
export PATH=$PATH:$GOROOT/bin
wget https://download.jetbrains.com.cn/go/goland-2021.3.3.tar.gz
sudo tar -zxvf goland-2021.3.3.tar.gz
mv GoLand-2021.3.3/ goland
/home/go/goland/bin/goland.sh
sudo apt-get install openssh-server
sudo vim /etc/ssh/sshd_config
,将Port注释去掉sudo vim /etc/ssh/sshd_config
,修改成如下sudo /etc/init.d/ssh restart
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。