Kasm
Container
Kasm Workspaces is a docker container streaming platform for delivering browser-based access to desktops, applications, and web services. Kasm uses devops-enabled Containerized Desktop Infrastructure (CDI) to create on-demand, disposable, docker containers that are accessible via web browser. Example use-cases include Remote Browser Isolation (RBI), Data Loss Prevention (DLP), Desktop as a Service (DaaS), Secure Remote Access Services (RAS), and Open Source Intelligence (OSINT) collections. The rendering of the graphical-based containers is powered by the open-source project KasmVNC.
Image details
Configuration
TypeContainerlinuxlinuxserver/kasm:latestYes3000:3000/tcp443:443/tcp/opt : /srv/lsio/kasm/opt/profiles : /srv/lsio/kasm/profiles/dev/input : /dev/input/run/udev/data : /run/udev/dataKASM_PORT=443DOCKER_HUB_USERNAME=USERDOCKER_HUB_PASSWORD=PASSDOCKER_MTU=1500unless-stoppedTemplate by technorabilia
Notes
Ensure to create the following volume directories on the host file system, or modify the paths in the volume mapping section under the advanced options below, as needed.
mkdir -p /srv/lsio/kasm/opt
mkdir -p /srv/lsio/kasm/profiles
Standalone Install
Select an install method, to see config/commands for deploying Kasm
Install on Portainer
Import all app templates into your Portainer instance, for easy 1-click deploys
- Ensure both Docker and Portainer are installed, and up-to-date
- Log into your Portainer web UI
- Under Settings → App Templates, paste the below URL
- Head to Home → App Templates, and the list of apps will show up
- Select Kasm, fill in any config options, and hit Deploy
Template Import URL
https://raw.githubusercontent.com/Lissy93/portainer-templates/main/templates.json
Show Me
More install options in our documentation.

The LinuxServer.io team brings you another container release featuring:
- regular and timely application updates
- easy user mappings (PGID, PUID)
- custom base image with s6 overlay
- weekly base OS updates with common layers across the entire LinuxServer.io ecosystem to minimise space usage, down time and bandwidth
- regular security updates
Find us at:
- Blog - all the things you can do with our containers including How-To guides, opinions and much more!
- Discord - realtime support / chat with the community and the team.
- Discourse - post on our community forum.
- GitHub - view the source for all of our repositories.
- Open Collective - please consider helping us by either donating or contributing to our budget
linuxserver/kasm
Kasm Workspaces is a docker container streaming platform for delivering browser-based access to desktops, applications, and web services. Kasm uses devops-enabled Containerized Desktop Infrastructure (CDI) to create on-demand, disposable, docker containers that are accessible via web browser. Example use-cases include Remote Browser Isolation (RBI), Data Loss Prevention (DLP), Desktop as a Service (DaaS), Secure Remote Access Services (RAS), and Open Source Intelligence (OSINT) collections.
The rendering of the graphical-based containers is powered by the open-source project KasmVNC.

Supported Architectures
We utilise the docker manifest for multi-platform awareness. More information is available from docker here and our announcement here.Simply pulling
lscr.io/linuxserver/kasm:latest should retrieve the correct image for your arch, but you can also pull specific arch images via tags.The architectures supported by this image are:
| Architecture | Available | Tag |
|---|---|---|
| x86-64 | ✅ | amd64-\ |
| arm64 | ✅ | arm64v8-\ |
Application Setup
This container uses Docker in Docker and requires being run inprivileged mode. This container also requires an initial setup that runs on port 3000.Unlike other containers the web interface port (default 443) needs to be set for the env variable
KASM_PORT and both the inside and outside port IE for 4443 KASM_PORT=4443 -p 4443:4443Unraid users due to the DinD storage layer
/opt/ should be mounted directly to a disk IE /mnt/disk1/appdata/path or optimally with a cache disk at /mnt/cache/appdata/pathAccess the installation wizard at https://
your ip:3000 and follow the instructions there. Once setup is complete access https://your ip:443 and login with the credentials you entered during setup. The default users are:- admin@kasm.local
- user@kasm.local
Currently Synology systems are not supported due to them blocking CPU scheduling in their Kernel.
Upgrading KASM
In order to upgrade Kasm, first make sure you are using the latest docker image, and then perform the in app update from the installation wizard. Docker image update and recreation of container alone won't upgrade Kasm.Following the upgrade, you will need to update any workspace image tags to match the new version.
GPU Support
During installation an option will be presented to force all Workspace containers to mount in and use a specific GPU. If using an NVIDIA GPU you will need to pass-e NVIDIA_VISIBLE_DEVICES=all or --gpus all and have the NVIDIA Container Toolkit installed on the host. Also if using NVIDIA, Kasm Workspaces has native NVIDIA support so you can optionally opt to simply use that instead of he manual override during installation.Gamepad support
In order to properly create virtual Gamepads you will need to mount from your host/dev/input and /run/udev/data. Please see HERE for instructions on enabling gamepad support.Persistant profiles
In order to use persistant profiles in Workspaces you will need to mount in a folder to use from your host to/profiles. From there when configuring a workspace you can set the Persistant Profile Path to IE /profiles/ubuntu-focal/{username}/, more infomation can be found HERE.Reverse proxy
A sample for SWAG can be found here. Post installation you will need to modify the "Proxy Port" setting under the default zone to 0 as outlined here to launch Workspaces sessions.Strict reverse proxies
This image uses a self-signed certificate by default. This naturally means the scheme ishttps.
If you are using a reverse proxy which validates certificates, you need to disable this check for the container.Usage
To help you get started creating a container from this image you can either use docker-compose or the docker cli.>!NOTE >Unless a parameter is flagged as 'optional', it is mandatory and a value must be provided.
docker-compose (recommended, click here for more info)
---
services:
kasm:
image: lscr.io/linuxserver/kasm:latest
container_name: kasm
privileged: true
security_opt:
- apparmor:rootlesskit #optional
environment:
- KASM_PORT=443
- DOCKER_HUB_USERNAME=USER #optional
- DOCKER_HUB_PASSWORD=PASS #optional
- DOCKER_MTU=1500 #optional
volumes:
- /path/to/kasm/data:/opt
- /path/to/kasm/profiles:/profiles #optional
- /dev/input:/dev/input #optional
- /run/udev/data:/run/udev/data #optional
ports:
- 3000:3000
- 443:443
stop_grace_period: "90s" #optional
restart: unless-stoppeddocker cli (click here for more info)
docker run -d \
--name=kasm \
--privileged \
--security-opt apparmor=rootlesskit `#optional` \
-e KASM_PORT=443 \
-e DOCKER_HUB_USERNAME=USER `#optional` \
-e DOCKER_HUB_PASSWORD=PASS `#optional` \
-e DOCKER_MTU=1500 `#optional` \
-p 3000:3000 \
-p 443:443 \
-v /path/to/kasm/data:/opt \
-v /path/to/kasm/profiles:/profiles `#optional` \
-v /dev/input:/dev/input `#optional` \
-v /run/udev/data:/run/udev/data `#optional` \
--stop-timeout="90s" `#optional` \
--restart unless-stopped \
lscr.io/linuxserver/kasm:latestParameters
Containers are configured using parameters passed at runtime (such as those above). These parameters are separated by a colon and indicate<external>:<internal> respectively. For example, -p 8080:80 would expose port 80 from inside the container to be accessible from the host's IP on port 8080 outside the container.| Parameter | Function |
|---|---|
-p 3000:3000 | Kasm Installation wizard. (https) |
-p 443:443 | Kasm Workspaces interface. (https) |
-e KASMPORT=443 | Specify the port you bind to the outside for Kasm Workspaces. |
-e DOCKERHUBUSERNAME=USER | Optionally specify a DockerHub Username to pull private images. |
-e DOCKERHUBPASSWORD=PASS | Optionally specify a DockerHub password to pull private images. |
-e DOCKERMTU=1500 | Optionally specify the mtu options passed to dockerd. |
-v /opt | Docker and installation storage. |
-v /profiles | Optionally specify a path for persistent profile storage. |
-v /dev/input | Optional for gamepad support. |
-v /run/udev/data | Optional for gamepad support. |
--stop-timeout= | Increase container shutdown delay to give Kasm services time to stop cleanly. |
--security-opt apparmor=rootlesskit | Some hosts require this on top of privileged for namespacing to work properly inside the DinD layer. |
Environment variables from files (Docker secrets)
You can set any environment variable from a file by using a special prependFILE__.As an example:
-e FILE__MYVAR=/run/secrets/mysecretvariableWill 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.Docker Mods
We publish various Docker Mods to enable additional functionality within the containers. The list of Mods available for this image (if any) as well as universal mods that can be applied to any one of our images can be accessed via the dynamic badges above.
Support Info
- Shell access whilst the container is running:
```bash
docker exec -it kasm /bin/bash
```- To monitor the logs of the container in realtime:
```bash
docker logs -f kasm
```- Container version number:
```bash
docker inspect -f '{{ index .Config.Labels "build_version" }}' kasm
```- Image version number:
```bash
docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/kasm:latest
```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:
```bash
docker-compose pull
```
* Single image:
```bash
docker-compose pull kasm
```- Update containers:
* All containers:
```bash
docker-compose up -d
```
* Single container:
```bash
docker-compose up -d kasm
```- You can also remove the old dangling images:
```bash
docker image prune
```Via Docker Run
- Update the image:
```bash
docker pull lscr.io/linuxserver/kasm:latest
```- Stop the running container:
```bash
docker stop kasm
```- Delete the container:
```bash
docker rm kasm
```- Recreate a new container with the same docker run parameters as instructed above (if mapped correctly to a host folder, your
/configfolder and settings will be preserved) - You can also remove the old dangling images:
```bash
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/docker-kasm.git
cd docker-kasm
docker build \
--no-cache \
--pull \
-t lscr.io/linuxserver/kasm:latest .The ARM variants can be built on x8664 hardware and vice versa using
lscr.io/linuxserver/qemu-staticdocker run --rm --privileged lscr.io/linuxserver/qemu-static --resetOnce registered you can define the dockerfile to use with
-f Dockerfile.aarch64.Versions
- 04.08.26: - Give kasmmanager a healthcheck start period so a cold start does not leave kasmproxy created but never started.
- 16.04.26: - Update for 1.18.1 release. Use rolling service images. Bump docker to v29.
- 13.11.25: - Pin docker to v28 to avoid API deprecation issues.
- 22.10.25: - Update for 1.18.0 release.
- 08.06.25: - Deprecate develop branch.
- 03.06.25: - Rebase to Ubuntu Noble. Update for 1.17.0 release.
- 09.11.24: - Update base image for 1.16.1 release.
- 24.09.24: - Add base users in docker build logic to survive container upgrades.
- 17.09.24: - Update base image for 1.16.0 release and fix Nvidia support.
- 16.02.24: - Update base image for 1.15.0 release.
- 22.08.23: - Update base image for 1.14.0 release.
- 07.04.23: - Add mod layer for ingesting LSIO images for 1.13.0 release.
- 28.03.23: - Pin compose to 2.5.0 to be in sync with upstream requirements.
- 05.11.22: - Rebase to Jammy, add support for GPUs, add support for Gamepads.
- 23.09.22: - Migrate to s6v3.
- 02.07.22: - Initial Release.
Serve Kasm on your own domain behind Caddy, Nginx or Traefik. Fill in your domain and copy the result. It's a starting point, some apps need their own base URL or extra headers set too.
Proxying kasm.example.com to http://Kasm:3000
Add this to your Caddyfile
kasm.example.com {
reverse_proxy http://Kasm:3000
}Check the logs first
Nine times out of ten the logs tell you exactly what went wrong.
- In Portainer, go to Containers, click the container, then Logs. Or run
docker logs Kasm - Exit codes help too:
137means killed, usually out of memory.126or127means the command inside the image is broken.
Port already in use
If deployment fails with "Bind for 0.0.0.0:3000 failed: port is already allocated", something else on your server is using that port.
- Find what's using it:
sudo ss -tlnp | grep :3000 - Stop the other service, or pick a different host port. In
3000:3000only the left number is yours to change, the right one belongs to the app.
Running but the page won't load
The container is up but nothing appears in your browser.
- Use your server's real IP:
http://your-server-ip:3000. The 0.0.0.0 link Portainer shows isn't a real address. - Give it a minute after first deploy, Kasm can take a while to initialise.
- Make sure your firewall allows the port, e.g.
sudo ufw allow 3000
Permission denied on volumes
If the logs show "permission denied", the app can't write to its data folder on the host.
- Fix the ownership:
sudo chown -R 1000:1000 /srv/lsio/kasm/opt(and the same for the other mapped folders)
Image won't pull
Test the pull directly on the host: docker pull linuxserver/kasm:latest
- "manifest unknown" means the tag no longer exists. This template uses
latest, so try pinning a specific version instead. - "toomanyrequests" is the Docker Hub rate limit. Log in with
docker loginto raise it. - "no space left on device" means a full disk. Reclaim space with
docker system prune
"exec format error"
This means the image was built for a different CPU architecture than your server.
- This image supports:
amd64, arm64 - Check yours with
uname -m: x86_64 is amd64, aarch64 is arm64. Raspberry Pi and other ARM boards are the usual culprits.
Container keeps restarting
The unless-stopped restart policy relaunches the app after every crash, so the real error can scroll past.
- Check the logs right after a restart, the last few lines before it died are the useful ones.
- Get the exit code with
docker inspect Kasm --format '{{.State.ExitCode}}' - Still stuck? Redeploy once with the restart policy set to
noso the failure stays visible.
Privileged mode
This template runs the container in privileged mode, giving it full access to your host.
- Only deploy it if you trust the app.
- If deployment is blocked, your Portainer security settings or hardened host may not allow privileged containers.
Raise an issue
Found something which isn't working as it should? Here's how to report it.
- Bug within the app: Open an issue within Kasm's repo
- Template not working: Open an issue on technorabilia/portainer-templates
- This website not working: Open an issue on lissy93/portainer-templates
A single container
Kasm runs as one container, the simplest kind of app here. Just the one image to pull and nothing else wired up alongside it.
The app image
An image is the app packed up ready to go, everything Kasm needs bundled into one download. This template pulls linuxserver/kasm:latest, which Docker fetches once (about 282 MB) and then starts your own copy from.
Where the image comes from
Docker pulls its images from registries, public libraries of ready-built apps. Kasm's comes from Docker Hub, published by linuxserver.
Version tags
The bit after the colon in the image name is the version tag. Here it's latest, which always points at the newest build, so a redeploy can bump you to a newer release without you asking. Newest right now is 1.19.0. Pin a specific tag if you would rather stay on one version.
Which machines it runs on
Every image is built for particular CPU types. This one ships for amd64, arm64, so it runs on both regular x86 servers and ARM boards like a Raspberry Pi.
Ports
A port is the door the app answers on. A mapping like 3000:3000 means it's reachable on port 3000 of your server, where the left number is yours to change and the right one belongs to the app. Once it's running, open http://your-server-ip:3000 in a browser. It opens:
3000:3000, likely the web interface443:443, likely the web interface
Volumes
A volume is where Kasm keeps its files so they survive an update or a restart. Without one, anything it saves would sit inside the container and vanish the moment it's recreated. This template mounts:
/optfrom/srv/lsio/kasm/opton the host/profilesfrom/srv/lsio/kasm/profileson the host/dev/inputfrom/dev/inputon the host/run/udev/datafrom/run/udev/dataon the host
Environment variables
Environment variables are the settings you hand over when you deploy, things like a password or a timezone. Kasm takes 4 of them, all with defaults you can leave alone or tweak:
KASM_PORT, defaults to443. Specify the port you bind to the outside for Kasm Workspaces.DOCKER_HUB_USERNAME, defaults toUSER. Optionally specify a DockerHub Username to pull private images. [OPTIONAL]DOCKER_HUB_PASSWORD, defaults toPASS. Optionally specify a DockerHub password to pull private images. [OPTIONAL]DOCKER_MTU, defaults to1500. Optionally specify the mtu options passed to dockerd. [OPTIONAL]
Restart policy
The restart policy here is unless-stopped, so Docker restarts Kasm after a crash or reboot, but leaves it off when you stop it on purpose. You can change this on the deploy screen. The choices are no (never restart), on-failure (only after a crash), unless-stopped (restart unless you stop it), and always (bring it back no matter what).
Networking
Nothing custom is set, so Kasm sits on Docker's default bridge network: its own private space that reaches the outside world only through the ports it publishes.
Container name
Once it's deployed, Portainer names the container Kasm. That's what you'll spot in the containers list and use in commands like docker logs Kasm.
Privileged mode
This template runs Kasm in privileged mode, which gives it nearly as much access to your server as the system itself. Some apps genuinely need it to reach hardware or manage the host, so it's one to run only if you trust the source.
Platform
The platform is linux, the kind of system the container is built to run on. Docker and Portainer handle this on a normal Linux server.
Portainer app templates
Zooming out, this whole page comes from a Portainer app template: a short recipe telling Portainer how to set Kasm up. Add the template list to Portainer once, then deploying Kasm is a click rather than a wall of config.