Sign in

code-server

4.146.0-ls12

Code-server is VS Code running on a remote server, accessible through the browser. - Code on your Chromebook, tablet, and laptop with a consistent dev environment. - If you have a Windows or Mac workstation, more easily develop for Linux. - Take advantage of large cloud servers to speed up tests, compilations, downloads, and more. - Preserve battery life when you're on the go. - All intensive computation runs on your server. - You're no longer running excess instances of Chrome.

docker pull ghcr.io/linuxserver-playground/code-server:latest
4.146.0-ls12 · amd64 · CI screenshot · test report

Quick start · configure#

Pick the optional settings and mods you want, set your paths, ports and values, then copy the result.

Image
Identity

The user the application runs as and its timezone.

Required
Contains all relevant configuration files.
web gui
Optional settings9

Tick what you need; it is added to every output with its value.

Mods

29 for code-server, 2 universal mods suggested for it, and 11 other universal mods. Ticked mods join one DOCKER_MODS value in the order you tick them.

---
services:
  code-server:
    image: ghcr.io/linuxserver-playground/code-server:latest
    container_name: code-server
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Etc/UTC
    volumes:
      - /path/to/code-server/config:/config
    ports:
      - 8443:8443
    restart: unless-stopped

Required settings only. Tick optional settings and mods to add them.

  • Replace the /path/to folders with real folders on your host; they are created if missing.

Install on …

Adding a store to your platform

Version tags#

TagLatest buildBuiltTests
:latestStable releasesbranch master · stable4.146.0-ls12amd64 · arm64 passed

Architectures#

Pulling :latest picks the right one for your host automatically.

  • x86_64amd64-latest
  • arm64arm64v8-latest

Inside the latest image#

ghcr.io/linuxserver-playground/code-server:4.146.0-ls12

Explore this build
Base image
ghcr.io/linuxserver-playground/baseimage-ubuntu:noble
Upstream version
4.146.0
amd64 compressed
328 MB · 10 layers
arm64 compressed
331 MB · 10 layers
amd64 packages
550 · Ubuntu 24.04.5 LTS
arm64 packages
550 · Ubuntu 24.04.5 LTS
Tests
passed
Built
Reason
weekly package check

In the fleet#

Live branches, their latest release, upstream version and next scheduled check.

code-server on the fleet board

live branchesloading…

Branch → tagLast buildReleasedUpstreamDriftNext checkFlags
master → :latestsuccess
4.146.0
? unknown––

Application setup#

Access the webui at http://<your-ip>:8443. For github integration, drop your ssh key in to /config/.ssh. Then open a terminal from the top menu and set your github username and email via the following commands

git config --global user.name "username"
git config --global user.email "email address"

Hashed code-server password

How to create the hashed password.

Parameters#

Ports#
PortFunctionRequired
8443:8443web guirequired
Environment variables#
VariableFunctionRequired
PUID=1000User IDrequired
PGID=1000Group IDrequired
TZ=Etc/UTCTimezonerequired
PASSWORD=passwordOptional web gui password, if PASSWORD or HASHED_PASSWORD is not provided, there will be no auth.optional
HASHED_PASSWORD=Optional web gui password, overrides PASSWORD, instructions on how to create it is below.optional
SUDO_PASSWORD=passwordIf this optional variable is set, user will have sudo access in the code-server terminal with the specified password.optional
SUDO_PASSWORD_HASH=Optionally set sudo password via hash (takes priority over SUDO_PASSWORD var). Format is $type$salt$hashed.optional
PROXY_DOMAIN=code-server.my.domainIf this optional variable is set, this domain will be proxied for subdomain proxying. See Documentation (opens in a new tab)optional
DEFAULT_WORKSPACE=/config/workspaceIf this optional variable is set, code-server will open this directory by defaultoptional
PWA_APPNAME=code-serverIf this optional variable is set, the PWA app will the specified name.optional
Volumes#
PathFunctionRequired
/configContains all relevant configuration files.required

Read-Only Operation#

This image can be run with a read-only container filesystem. For details please read the docs.

Caveats

  • /tmp must be mounted to tmpfs
  • sudo will not be available

Non-Root Operation#

This image can be run with a non-root user. For details please read the docs.

Caveats

  • sudo will not be available

Environment variables from files (Docker secrets)#

You can set any environment variable from a file by using a special prepend FILE__.

As an example:

-e FILE__MYVAR=/run/secrets/mysecretvariable

Will set the environment variable MYVAR based on the contents of the /run/secrets/mysecretvariable file.

Umask for running applications#

For all of our images we provide the ability to override the default umask settings for services started within the containers using the optional -e UMASK=022 setting. Keep in mind umask is not chmod it subtracts from permissions based on it’s value it does not add. Please read up here before asking for support.

User / Group Identifiers#

When using volumes (-v flags), permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user PUID and group PGID.

Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish like magic.

In this instance PUID=1000 and PGID=1000, to find yours use id your_user as below:

id your_user

Example output:

uid=1000(your_user) gid=1000(your_user) groups=1000(your_user)

Updating Info#

Most of our images are static, versioned, and require an image update and container recreation to update the app inside. With some exceptions (noted in the relevant readme.md), we do not recommend or support updating apps inside the container. Please consult the Application Setup section above to see if it is recommended for the image.

Below are the instructions for updating containers:

Via Docker Compose

  • Update images:

    • All images:

      docker-compose pull
    • Single image:

      docker-compose pull code-server
  • Update containers:

    • All containers:

      docker-compose up -d
    • Single container:

      docker-compose up -d code-server
  • You can also remove the old dangling images:

    docker image prune

Via Docker Run

  • Update the image:

    docker pull ghcr.io/linuxserver-playground/code-server:latest
  • Stop the running container:

    docker stop code-server
  • Delete the container:

    docker rm code-server
  • Recreate a new container with the same docker run parameters as instructed above (if mapped correctly to a host folder, your /config folder and settings will be preserved)

  • You can also remove the old dangling images:

    docker image prune

Image Update Notifications - Diun (Docker Image Update Notifier)

Tip

We recommend Diun for update notifications. Other tools that automatically update containers unattended are not recommended or supported.

Building locally#

If you want to make local modifications to these images for development purposes or just to customize the logic:

git clone https://github.com/linuxserver-playground/docker-code-server.git
cd docker-code-server
docker build \
  --no-cache \
  --pull \
  -t ghcr.io/linuxserver-playground/code-server:latest .

The ARM variants can be built on x86_64 hardware and vice versa using ghcr.io/linuxserver/qemu-static

docker run --rm --privileged ghcr.io/linuxserver/qemu-static --reset

Once registered you can define the dockerfile to use with -f Dockerfile.aarch64.

Every push builds and tests the image with the shared workflow in linuxserver-playground/workflows; every build’s tests, screenshots and package changes are on the image’s builds on the website.

Builds#

The newest five builds per branch, each with its CI report; 8 older releases are on GitHub, listed below.

TagBuiltReasonChangeResultSize
4.146.0-ls12master · 0400b38aweekly package checkbasesuccess328 MB amd64331 MB arm64
4.146.0-ls11master · 4e778e8aupstream checkmixedsuccess334 MB amd64336 MB arm64
4.145.2-ls10master · f91ec372weekly package checkbasesuccess305 MB amd64305 MB arm64
4.145.2-ls9master · 6a7474e7weekly package checkbasesuccess299 MB amd64299 MB arm64
4.145.2-ls8master · 3e09b1bbupstream checkmixedsuccess301 MB amd64301 MB arm64
Older releases8Release, run record and run on GitHub

Mods#

Add a mod with DOCKER_MODS=<image>; separate several with |.

All mods for code-server
  • AWSCLI

    This mod adds AWSCLI to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-awscli
  • Bat

    This mod adds bat to code-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-bat
  • .NET Core SDK

    This mod adds .NET CORE SDK to code-server and openvscode-server.

    ghcr.io/linuxserver-playground/mods:code-server-dotnet
  • Extension Arguments

    This mod installs code-server/openvscode-server extensions at startup. The list of extensions to be installed should be provided using environment variable VSCODEEXTENSIONIDS separated by |.

    ghcr.io/linuxserver-playground/mods:code-server-extension-arguments
  • Flutter Beta

    This mod adds a Flutter beta dev environment to code-server and openvscode-server, to be installed/updated during container start. The environment is already configured to run browser apps.

    ghcr.io/linuxserver-playground/mods:code-server-flutter
  • Golang

    This mod adds golang/go to code-server and openvscode-server.

    ghcr.io/linuxserver-playground/mods:code-server-golang
  • Java11

    This mod adds a java11 dev environment to code-server and openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-java11
  • Julia

    This mod adds a Julia dev environment to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-julia
  • Nodejs

    This mod adds a nodejs dev environment to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-nodejs
  • NPM Global

    This mod sets the NPM global folder to /config in code-server/openvscode-server during container start.

    ghcr.io/linuxserver-playground/mods:code-server-npmglobal
  • nvm

    This mod adds Node Version Manager to linuxserver/code-server and linuxserver/openvscode-server, to be installed during container start.

    ghcr.io/linuxserver-playground/mods:code-server-nvm
  • php

    This mod adds php and composer to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-php
  • PHP-CLI

    This mod adds php-cli and composer to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-php-cli
  • PHP8

    This mod adds php8.2 and composer to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-php8
  • pnpm

    This mod adds PNPM to linuxserver/code-server and linuxserver/openvscode-server, to be installed during container start.

    ghcr.io/linuxserver-playground/mods:code-server-pnpm
  • PowerShell

    This mod adds PowerShell to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-powershell
  • Prolog

    This mod adds prolog to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-prolog
  • Python3

    This mod adds a python3 dev environment to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-python3
  • Python3 + Poetry

    This mod adds a python3 dev environment to code-server/openvscode-server, to be installed/updated during container start, setting up a python3 environment with poetry.

    ghcr.io/linuxserver-playground/mods:code-server-python3-poetry
  • R

    This mod adds a R dev environment to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-r
  • Rbenv

    This mod adds rbenv to code-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-rbenv
  • ROS2

    This mod adds ROS2 to code-server and openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-ros2
  • Rust

    This mod adds Rust to code-server and openvscode-server.

    ghcr.io/linuxserver-playground/mods:code-server-rust
  • scikit-learn

    This mod adds scikit-learn and jupyter to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-scikit-learn
  • ShellCheck

    This mod adds ShellCheck to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-shellcheck
  • SSL

    This mod adds SSL capabilities to code-server.

    ghcr.io/linuxserver-playground/mods:code-server-ssl
  • SVN

    This mod installs subversion and the SVN extension into code-server/openvscode-server at startup.

    ghcr.io/linuxserver-playground/mods:code-server-svn
  • Terraform

    This mod adds the Terraform binary and extension to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-terraform
  • Zsh / Oh My Zsh

    This mod adds zsh and Oh My Zsh to code-server/openvscode-server, to be installed/updated during container start.

    ghcr.io/linuxserver-playground/mods:code-server-zsh
  • Dockeruniversal

    This mod adds the docker binary as wells as the buildx and the compose plug-ins to any linuxserver image.

    ghcr.io/linuxserver-playground/mods:universal-docker
  • Docker-in-docker (dind)universal

    This mod adds docker-in-docker (dind) to Ubuntu and Alpine based images, to be installed/updated during container start. Main advantage is that all docker images, containers, volumes, etc. will reside inside the container and will be sandboxed from the host's docker environment.

    ghcr.io/linuxserver-playground/mods:universal-docker-in-docker

Plus 11 other universal mods that work with every image.

Reverse proxy#

code-server listens on http://code-server:8443.

What you named the code-server container; SWAG resolves it on the shared network.

Uncomments the matching include lines; API locations stay open so client apps keep working.

  • Save as /config/nginx/proxy-confs/code-server.subdomain.conf in SWAG (drop the .sample) and restart SWAG.
  • Your DNS needs a record for code-server.yourdomain.com (a CNAME to the domain, or a wildcard), and SWAG's SUBDOMAINS must cover it.
  • The code-server container and SWAG must share a user-defined Docker network so the name resolves.
## Version 2026/11/26
# make sure that your code-server container is named code-server
# make sure that your dns has a cname set for code-server

server {
    listen 443 ssl;
#    listen 443 quic;
    listen [::]:443 ssl;
#    listen [::]:443 quic;

    server_name code-server.*;

    include /config/nginx/ssl.conf;

    client_max_body_size 0;

    # enable for ldap auth (requires ldap-location.conf in the location block)
    #include /config/nginx/ldap-server.conf;

    # enable for Authelia (requires authelia-location.conf in the location block)
    #include /config/nginx/authelia-server.conf;

    # enable for Authentik (requires authentik-location.conf in the location block)
    #include /config/nginx/authentik-server.conf;

    # enable for Tinyauth (requires tinyauth-location.conf in the location block)
    #include /config/nginx/tinyauth-server.conf;

    location / {
        # enable the next two lines for http auth
        #auth_basic "Restricted";
        #auth_basic_user_file /config/nginx/.htpasswd;

        # enable for ldap auth (requires ldap-server.conf in the server block)
        #include /config/nginx/ldap-location.conf;

        # enable for Authelia (requires authelia-server.conf in the server block)
        #include /config/nginx/authelia-location.conf;

        # enable for Authentik (requires authentik-server.conf in the server block)
        #include /config/nginx/authentik-location.conf;

        # enable for Tinyauth (requires tinyauth-server.conf in the server block)
        #include /config/nginx/tinyauth-location.conf;

        include /config/nginx/proxy.conf;
        include /config/nginx/resolver.conf;
        set $upstream_app code-server;
        set $upstream_port 8443;
        set $upstream_proto http;
        proxy_pass $upstream_proto://$upstream_app:$upstream_port;

    }
}

Default sample.

Source: linuxserver-playground.github.io/hub/api/v1/catalog/code-server/proxy.json

Changelog#

  1. Add fallback for legacy or misconfigured systems without IPv6 support.

  2. Fix container only listening on IPv6 when running non-root.

  3. Let server listen on both ipv4 and ipv6.

  4. Allow setting PWA name using env var PWA_APPNAME.

  5. Only chown config folder when change to ownership or new install is detected.

  6. Manage permissions in /config/.ssh according to file type

  7. Rebase to Ubuntu Noble.

  8. Deprecate armhf. As announced here (opens in a new tab)

23 earlier entries
  1. Install recommended deps to maintain parity with the older images.
  2. Rebase to jammy, switch to s6v3. Fix chown logic to skip /config/workspace contents.
  3. Install using the official tarballs.
  4. Add install-extension as a helper for mods to install extensions.
  5. Add DEFAULT_WORKSPACE env var.
  6. Rebase to Ubuntu focal.
  7. Fix slow chown on large workspace (contents of workspace folder no longer chowned).
  8. Bump node to 14 to fix builds
  9. Fix doc link
  10. Allow setting gui password via hash using env var HASHED_PASSWORD.
  11. Allow setting sudo password via hash using env var SUDO_PASSWORD_HASH.
  12. Add --domain-proxy support.
  13. Shrink images, install via yarn, fix arm32v7 build.
  14. Switch to multi-arch images, install via npm.
  15. Update start arguments.
  16. Structural changes required for v3.
  17. Fix artifact url retrieval from github.
  18. Upgrade to v2 builds.
  19. Update project logo.
  20. Add development builds/tag.
  21. Add optional sudo access.
  22. Add nano.
  23. Initial Release.

Support#

Questions about running code-server? Start with the documentation and the community; open an issue for bugs.

  • Shell access whilst the container is running:

    docker exec -it code-server /bin/bash
  • To monitor the logs of the container in realtime:

    docker logs -f code-server
  • Container version number:

    docker inspect -f '{{ index .Config.Labels "build_version" }}' code-server
  • Image version number:

    docker inspect -f '{{ index .Config.Labels "build_version" }}' ghcr.io/linuxserver-playground/code-server:latest

Community project

Improve code-server

This image is kept up by volunteers, and you can be one of them. You don't need to know how the pipeline works: point an AI agent at the harness and describe what you want. It reproduces the problem in your Docker, tests the change and drafts the pull request for you to check.

Ask your agent

  • Something is wrong with the code-server image: <what you saw>. Reproduce it, fix it and draft the PR.
  • Add <package> to the code-server image, test it and draft the PR.
  • Make a mod for code-server that <what you need>, and test it.

Contributing an image Every way to help Get the harness (opens in a new tab)

Related

Browse all

github-desktop

release-3.4.13-linux1-ls9

Github Desktop is an open source Electron-based GitHub app. It is written in TypeScript and uses React.

0 GitHub starsselkiesarm64

gitqlient

v1.6.3-ls7

GitQlient is a multi-platform Git client originally forked from QGit. Nowadays it goes beyond of just a fork and adds a lot of new functionality.

0 GitHub starsalpinearm64

intellij-idea

2026.3.0.1-ls12

IntelliJ IDEA helps you write code faster with tools that eliminate tedious tasks and let you focus on what matters – building great software.

0 GitHub starsselkies

pycharm

2026.3.0.2-ls14

PyCharm offers out-of-the-box support for Python, databases, Jupyter, Git, Conda, PyTorch, TensorFlow, Hugging Face, Django, Flask, FastAPI, and more.

0 GitHub starsselkies