OpenVSCode Server
Overview
OpenVSCode Server, by Gitpod, runs the full Visual Studio Code editor as a service you reach from any browser. You get the same VS Code experience, including the editor, the extension marketplace, the integrated terminal and workspace state, hosted on your own cloud VM. You can develop from a Chromebook, a tablet or a locked-down workstation while the code, tools and compute stay on the server.
A browser IDE with an integrated terminal is effectively remote code execution on the VM, so the SecureAnyCloud image is secure by default. OpenVSCode Server 1.109.5 runs as a dedicated unprivileged openvscode account bound to the loopback connector 127.0.0.1:3000. nginx fronts it over TLS on port 443 with the WebSocket upgrade the editor requires. A unique, high-entropy connection token is generated on the first boot of every VM. There is no default login, and the token gates all access to the editor.
What you get:
- OpenVSCode Server 1.109.5 (Gitpod's open-source VS Code in the browser), managed by systemd.
- The VS Code web IDE fronted by nginx on
:443over TLS, with:80redirecting to HTTPS and the WebSocket upgrade proxied. - OpenVSCode Server running as the unprivileged
openvscodeuser, bound to127.0.0.1:3000. - A unique connection token generated on first boot and recorded in a root-only file, with no default login.
- A per-VM self-signed TLS certificate generated on first boot, ready to be replaced with your own.
openvscode-server.serviceandnginx.serviceas systemd units, enabled and active.- An unauthenticated
/healthzendpoint for Azure Load Balancer health probes. - 24/7 SecureAnyCloud support.
Prerequisites
- An active Azure subscription, an SSH key pair, and a virtual network and subnet in the target region.
- Standard_B2s (2 vCPU / 4 GiB RAM) is a reasonable starting point. Size up for heavier extensions, language servers or multiple concurrent workspaces.
- Network security group (NSG) inbound rules: allow
22/tcpfrom your management network,443/tcpfor the editor and, optionally,80/tcp, which only redirects to HTTPS. The raw editor port3000stays on loopback and is never exposed. - The image ships with a self-signed certificate, so your browser warns on first connection. See Maintenance to install a real certificate.
- The integrated terminal can run arbitrary code, including outbound network calls. Keep inbound access restricted to trusted networks.
Step 1 - Deploy from the Azure Marketplace
Sign in to the Azure Portal and choose Create a resource. Search the Marketplace for OpenVSCode Server by SecureAnyCloud, then select Create.
On the Basics tab, pick your subscription, resource group, region and size. Under Administrator account, choose SSH public key and paste your key. Under Inbound port rules, allow SSH (22) and HTTPS (443).
Choose Review + create, then Create.
Step 2 - Deploy from the Azure CLI
Accept the Marketplace terms once per subscription, then create the VM and open port 443:
# Accept the Marketplace terms once per subscription (required before the first CLI deploy)
az vm image terms accept --urn sac1647283583153:openvscode-server:default:latest
az vm create \
--resource-group <your-rg> \
--name openvscode-server \
--image sac1647283583153:openvscode-server:default:latest \
--size Standard_B2s \
--admin-username azureuser \
--ssh-key-values ~/.ssh/id_ed25519.pub \
--vnet-name <your-vnet> --subnet <your-subnet> \
--public-ip-sku Standard
az vm open-port --resource-group <your-rg> --name openvscode-server --port 443 --priority 1010Step 3 - Connect to your VM
Connect over SSH as the azureuser account:
ssh azureuser@<vm-public-ip>Step 4 - Confirm the services are running
Check that both services are active:
systemctl is-active openvscode-server.service nginx.serviceBoth report active.
OpenVSCode Server runs as the dedicated unprivileged openvscode user and listens only on the loopback connector 127.0.0.1:3000. nginx fronts it on port 443 over TLS with the WebSocket upgrade the editor requires. Because the editor runs as a non-root account, a browser terminal session never has needless privilege on the VM.
Step 5 - Retrieve your connection token
The connection token is generated uniquely on the first boot of your VM. It is written to a root-only file, along with the URL to open:
sudo cat /root/openvscode-credentials.txtThis file contains OPENVSCODE_CONNECTION_TOKEN and OPENVSCODE_URL. There is no username. The token alone gates access, and anyone with the URL has an interactive shell on the VM as the openvscode user. Treat the token like a password and store it somewhere safe.
Step 6 - Confirm the health endpoint
nginx serves an unauthenticated health endpoint for load balancers and probes. Request it with:
curl -s http://localhost/healthzIt returns ok. This endpoint never requires the token, so it is safe for an Azure Load Balancer health probe. Every editor request still requires authentication.
Step 7 - Verify the token gates access from the command line
OpenVSCode Server rejects any request with no token or a wrong token (HTTP 403). It accepts the per-VM token with a redirect into the workbench (HTTP 302).
The command embeds your unique token, so run it interactively rather than from a script. Substitute the value of OPENVSCODE_CONNECTION_TOKEN from Step 5 for <OPENVSCODE_TOKEN>:
curl -sk -o /dev/null -w 'no token -> %{http_code}\n' https://127.0.0.1/
curl -sk -o /dev/null -w 'per-VM tok -> %{http_code}\n' "https://127.0.0.1/?tkn=<OPENVSCODE_TOKEN>"The first line prints 403 (denied), the second prints 302 (accepted). The -k flag tells curl to accept the image's self-signed certificate.
Step 8 - Open the editor in your browser
Browse to the OPENVSCODE_URL from Step 5, which has the form https://<vm-public-ip>/?tkn=<your-token>. Your browser warns once about the self-signed certificate. Accept it, or install a real certificate first (see Maintenance).
OpenVSCode Server validates the token, sets a session cookie and opens a full Visual Studio Code editor in your browser.
Use the Explorer to open a file in the workspace and start editing. The default workspace folder is /var/lib/openvscode-server/workspace, owned by the openvscode user.
Open the integrated terminal with Terminal > New Terminal to run commands on the VM without leaving the editor. The terminal runs as the unprivileged openvscode user.
Open the Extensions panel from the activity bar to browse and install extensions from the marketplace, such as language support, linters and themes.
Maintenance
- Connection token. The per-VM token lives in
/etc/openvscode-server/connection-token. To rotate it, write a new secret (for exampleopenssl rand -hex 24 | sudo tee /etc/openvscode-server/connection-token) and runsudo systemctl restart openvscode-server. Then updateOPENVSCODE_URLfor your users. - TLS certificate. The image ships a per-VM self-signed certificate at
/etc/nginx/tls/openvscode.crt. For production, replace it with a certificate for your own domain, for example with certbot:
text sudo apt-get install -y certbot python3-certbot-nginx sudo certbot --nginx -d ide.example.com
- Extensions. Install extensions from the Extensions panel in the IDE. They persist under the
openvscodeuser's home at/var/lib/openvscode-server. - Storage. The workspace and editor state live under
/var/lib/openvscode-server. Back up that directory to protect your files, settings and extensions, and grow the OS disk if you need more room. - Network egress. The integrated terminal can run arbitrary code that reaches the internet. Restrict outbound rules on the NSG if you need to limit what the editor can contact.
- Tuning. The service is defined in
/etc/systemd/system/openvscode-server.service, with memory and task limits. After any change, runsudo systemctl daemon-reload && sudo systemctl restart openvscode-server. - Security patches. Unattended upgrades remain enabled, so the OS continues to receive security updates automatically.
Support
SecureAnyCloud provides 24/7 expert support for this image. Contact sales@secureanycloud.com.
Deploy on Azure
Launch OpenVSCode Server on Ubuntu 24.04 LTS on Azure with 24/7 support from SecureAnyCloud.
View this image
Need Help?
Our support team is available 24/7.
sales@secureanycloud.com