Deploy Code Server on Ubuntu with Docker — run VS Code in your browser, develop from any device with a consistent environment.
Grab the automated bash script from GitHub to follow along with the video.
wget https://raw.githubusercontent.com/mhmdali94/Docker/main/dev/code-server/code-server-ubuntu.sh
chmod +x code-server-ubuntu.sh
sudo bash code-server-ubuntu.sh
wget https://raw.githubusercontent.com/mhmdali94/Docker/main/dev/code-server/code-server-ubuntu.sh
chmod +x code-server-ubuntu.sh
The script installs Docker if needed, then deploys Code Server with persistent workspace storage.
sudo bash code-server-ubuntu.sh
Open browser and navigate to:
http://<your-server-ip>:8080
Log in with your password, install your favorite VS Code extensions from the marketplace, and configure settings — everything persists across restarts.
# Retrieve the auto-generated password
docker exec -it code-server cat /home/coder/.config/code-server/config.yaml
| Port | Purpose |
|---|---|
| 8080 | Code Server Web UI |
code-server runs VS Code entirely in the browser, giving you a full development environment accessible from any device with an internet connection. It is ideal for teams that want a consistent, cloud-based IDE without installing anything locally.
Code Server gives you a full VS Code experience — extensions, themes, terminal, git integration — accessible from any browser on any device. Your workspace lives on a powerful server instead of your laptop: builds are faster, data never leaves your infrastructure, and you can switch devices mid-session without losing state. Perfect for developers working on tablets, Chromebooks, or shared machines.
Port 8080 for the web UI. Put Nginx Proxy Manager in front on 443 with HTTPS. Never expose 8080 directly to the internet. The integrated terminal runs on your server — treat this port as highly sensitive.
Direct alternatives: Coder (team-scale, Terraform workspaces), Theia (more open, Eclipse-based), VS Code Tunnel (official VS Code remote, no self-hosting needed). Cloud: GitHub Codespaces (tight GitHub integration), Gitpod (generous free tier). Code Server is best when you want VS Code in a browser for personal/small-team use without complexity.
Don't use Code Server for a team of more than 2-3 people — Coder is built for team management, quotas, and multi-user workspace lifecycle. And if you just want remote VS Code access to your local machine, VS Code Tunnel (built into VS Code) is simpler and requires no server setup.
PrismaTechWork provides end-to-end infrastructure services — from initial deployment and security hardening to ongoing monitoring, automated backups, and dedicated support. Whether you need a single-server setup or a multi-site network, our team ensures your infrastructure is built right, secured properly, and maintained reliably.
Almost — Code Server uses the VS Code open-source core (Code OSS). The extension marketplace, Microsoft Live Share, and Copilot have restrictions due to Microsoft's licensing. Most extensions work fine; a small number require the official VS Code binary.
Yes — install extensions from the marketplace inside Code Server. For settings, you can copy your `settings.json` and `keybindings.json` into the container. VS Code Settings Sync (GitHub-based) works with some limitations.
No — Code Server is designed for a single user. For multi-user setups, run separate Code Server instances per user (each on a different port) or use Coder which manages multi-user workspaces.
Yes — Code Server forwards ports automatically. When your app starts on port 3000 inside the container, Code Server proxies it through its own URL. Click the 'Open in Browser' notification or use the Ports panel.
Download the `.vsix` file from the VS Code Marketplace or GitHub releases, then drag it into Code Server or install via CLI: `code-server --install-extension /path/to/extension.vsix`.
Yes — Code Server has ARM64 builds. Performance will be limited on Raspberry Pi (recommend Pi 4 with 4 GB RAM minimum). It works well for light editing and scripting tasks.
Use SSH keys (mount `~/.ssh` into the container) or HTTPS with a git credential helper. For GitHub: `git config --global credential.helper store` and authenticate once, then credentials persist in the workspace volume.
Run `docker compose pull && docker compose up -d`. Your workspace files and extensions persist in the mounted volume. No migration steps are needed for minor upgrades — check the changelog for major version changes.