It is a tutorial about setup a code-server for your remote coding.
First, run these commands on your terminal.
sudo apt install npm -y
sudo npm install -g n
sudo curl -fsSL https://code-server.dev/install.sh | sh
Second execute code-server
to init config.yaml
file.
Last, modify nano ./.config/code-server/config.yaml to set ip : 0.0.0.0 and password:
bind-addr: 0.0.0.0:8080
auth: password
password: 123456
cert: false
Currently, you can open http://ip:8080
to open vscode in webbrowser.
In addtion, I create a autostart config file to make it autostart when computer startup on Ubuntu. If you want to do the same thing, look at what I did:
write these lines into ~/.config/autostart/code-server.desktop
[Desktop Entry]
Name=code-server
Exec=nohup code-server > /dev/null
StartupNotify=true
Terminal=false
Type=Application
X-GNOME-Autostart-Delay=15