Skip to content

Using the Docker Image

Marc Hanheide edited this page Jan 28, 2023 · 25 revisions

Using the Module's Docker Image

All software required is deployed as a Docker image, allowing anyone to run this on any computer that has Docker installed. The containerised development environment is based on KASM Community Edition images, heavily customised for the work within the Lincoln Centre for Autonomous Systems (L-CAS) and to contain a ROS2 development environment.

Install Docker on your computer (optional if you want to use your own computer)

To install Docker on your own computer (not needed, if you are using the SoCS lab computers!!), make sure you follow the instructions for your OS (Windows, MacOS, Linux) at https://docs.docker.com/get-docker/. Make sure you also have docker-compose installed (is default in the standard installation packages, so normally nothing needs to be done).

Getting the docker-compose file

The deployment of a Docker container can be made very easy and straight forward with the use of docker-compose. The configuration file for this module should be downloaded from https://raw.githubusercontent.com/LCAS/kasm-workspaces-core-images/develop/kasm-lcas-jammy.docker-compose.yaml. Save this single configuration file in a directory (e.g named lcas-docker, or similar). It is from this folder that you will start your docker container, so remember where it is.

Starting up your container

  1. Open a terminal / powershell on your computer
  2. Log in to the L-CAS docker registry, i.e. run docker login lcas.lincoln.ac.uk, with user name lcas, and password lincoln
  3. Navigate to the directory where you have saved the file kasm-lcas-jammy.docker-compose.yaml (see above).
  4. In this directory run docker compose -f kasm-lcas-jammy.docker-compose.yaml pull. When you do this the very first time it will take quite a long time, as the image is being downloaded first from the registry. It's advisable to run this every time before you start working, to ensure you always have the latest version. It only takes long when done the first time, really.
  5. Still in the directory, run docker compose -f kasm-lcas-jammy.docker-compose.yaml up -d, which will start the container with the virtual desktop
  6. open https://localhost:6901 in your browser (Chrome works best). Use username kasm_user with password password to log in. You can now develop in the provided desktop environment
  7. once you have completed your work, make sure to stop the container with the command docker compose -f kasm-lcas-jammy.docker-compose.yaml down

Note: Any changes you have been done in your home directory on this desktop are retained and will still be there when you start the container again next time, but you must never assume that the data is safe. Always keep a copy of all your source code (i.e. push to GitHub or the likes).

This is what it looks like

desktop-video

Clone this wiki locally