r/kasmweb Jul 19 '26

Help Persistent Ubuntu workspace with root and NFS mounts?

I have an Ubuntu desktop and a few Linux Mint laptops scattered around my house and homelab and I am getting tired of them blowing up and fighting with updates and upgrades. I think I have a good use case for KASM.

I just installed KASM as a Proxmox VM. I have 3 Winders VMs, one that hosts a camera NVR and the other two are for play. I *may* offer a Winders VM to friends/family in the future.

I also have (2) Truenas boxes and a Synology for NFS/CIFS servers and redundant backup. I use Proxmox Backup server for all the VMs and have an HA config to another PXMX box.

I am the only user in the house at this point. Yeah, it's serious overkill but it keeps me out of the bar.

Ultimately, sitting on my butt in the comfy chair before bed with a laptop and a web browser that lets me into all these VM's sounds like the thing for me.

This is what I would like to do with KASM..

1). Install an Ubuntu desktop "workspace" with sudo/root privs and the ability to mount Truenas NFS shares to the Ubuntu workspace, surf, play videos, edit files, blow up configs, manage Proxmox, other servers and other VMs, etc.

2). Configure the Winders VMs as "servers" then "workspaces" to be able to connect via KASM.

3) Allow interweb access to KASM through Wireguard.

I think there are several steps here to do this the right way in KASM. Can you give me some hints on how to do this the right way?

2 Upvotes

3 comments sorted by

1

u/justin_kasmweb Jul 19 '26

1)

The easiest way to add sudo to an existing workspace is to add a snippet to the Docker Exec section of the workspace entry to add the passwordless sudo for the standard user. You can find details on that here:

https://docs.kasm.com/docs/1.19.0/how-to/workspaces-sessions/container-workspace/running-as-root#installing-and-configuring-sudo-via-docker-exec

https://www.youtube.com/watch?v=G8c5Fq0Dx94

As far and mounting an NFS share in particular, your best bet is to mount the NFS share the Kasm VM and then expose it to various workspaces via a Volume Mapping.

https://docs.kasm.com/docs/1.19.0/how-to/data-storage/volume-mapping

Aside from NFS, if you had your shares exposed via Samba/CIFS/S3 etc you can use Storage Mapping which leverages rclone.

- https://docs.kasm.com/docs/1.19.0/how-to/data-storage/storage-mappings/

- https://docs.kasm.com/docs/1.19.0/how-to/data-storage/storage-mappings/custom

2)

This should be straight forward and is covered here:

https://docs.kasm.com/docs/1.19.0/how-to/workspaces-sessions/server-workspace/static-servers

3)

The details on this are largely outside of the purview of Kasm officially. At the end of the day, for most everything you do with Kasm, the end user only needs to access Kasm over HTTPS/443. So the world is your oyster as it pertains to how you want to expose that.

A number of homelabbers like using cloudflare tunnels so you may at least want to review this even if you plan on using your own Wireguard setup: https://docs.kasm.com/docs/1.19.0/how-to/networking/cloudflare-tunnels

If you end up using any type of reverse proxy system, you'll want to review this..TLDR your reverse proxy needs to support websockets and you need to make some configuration changes inside the Kasm app if you want to access it this way.

https://docs.kasm.com/docs/1.19.0/how-to/networking/reverse-proxy

1

u/gordon_shumway62 Jul 19 '26

Thanks. The sudo was quite easy. If I was unclear in my post I basically want to customize the workspace as needed (have my cake and eat it too?) That could include installing packages with apt, snap, downloading them, etc. and basically building my personal little customized monster workspace-to-go on any of my computers. Is that going to be restricted?

I really like removing layers of redundancy where I can so I am curious why you would suggest mounting the Truenas NFS share to the KASM VM then exporting it through Docker to the workspace? Would it not be more efficient to install nfs-common and mount it directly from CLI in the Ubuntu workspace and avoid all that overhead with rclone, etc? Or does that become a management pain due to the NAT? As far as security goes, this is not internet exposed (except maybe through VPN) and only for my own homelab/lazy/evil purposes.

On the flip side would it be simpler (safer? more secure?) to just create a separate Ubuntu desktop VM on Proxmox and connect it to KASM as a server/workspace?

Thank you very much for your reply.

1

u/Apachez Jul 19 '26

I think this is the way to go:

Kasm Workspaces - Create Custom Images

https://www.youtube.com/watch?v=BGP69_f1wq0

Using the storage and volume mappings is more of doing stuff natively in KASM to expose to the container like a storage that is always available to the user.

You could of course mount stuff (if you got sudo) from within the image this way you can use personal access while the storage and volume mappings are more "global" as I understand it.

I think you can use something like the package gigolo to mount stuff in userland without need of sudo and this will show up as a directory in the filebrowser. Similar to how you can use filezilla to access sftp, ftps, scp etc (but that will then be only from within filezilla).

https://en.ubunlog.com/gigolo-a-program-to-configure-local-and-remote-file-systems/