-
Notifications
You must be signed in to change notification settings - Fork 30
Using the 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.
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).
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.
- Open a terminal / powershell on your computer
- Log in to the L-CAS docker registry, i.e. run
docker login lcas.lincoln.ac.uk, with user namelcas, and passwordlincoln - Navigate to the directory where you have saved the file
kasm-lcas-jammy.docker-compose.yaml(see above). - In this directory run
docker compose -f kasm-lcas-jammy.docker-compose.yaml pull(on slightly older docker installations the command is acutallydocker-composewith a-). 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. - 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 (again, on your installation it may bedocker-composewith a-) - open https://localhost:6901 in your browser (Chrome works best). Use username
kasm_userwith passwordpasswordto log in. You can now develop in the provided desktop environment
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). Also, this means if anyone else starts the container, they have access to all your data, unless you delete them, see next section. You must NOT leave any personal data (including logins and password) on the lab PCs when you leave, so it's important you clean up after yourself
Note: If you have installed docker with sudo on linux, you may receive the following error message when logging in Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post "http://%2Fvar%2Frun%2Fdocker.sock/v1.24/auth": dial unix /var/run/docker.sock: connect: permission denied if so, run all docker commands beginning with sudo or add your user to the docker group.
- stop all processes inside the virtual desktop (e.g. with
[ctrl-c]in the terminals) - make sure you have saved all your work somewhere, e.g. on github, uploaded to OneDrive (browser), or on Teams (you can have a chat with yourself to keep notes and files!)
- If you are on a shared computer (e.g. the lab PCs), make sure you log out of everything and you removed any password files etc.
- make sure to stop the container with the command
docker compose -f kasm-lcas-jammy.docker-compose.yaml down -
If you are on a shared computer (e.g. the lab PCs) and you want to really make sure all your personal information is removed, simply run
docker volume rm kasm_lcas_jammy_home_rootto wipe all user files. Then, next time the container is restarted, it starts we a blank user directory (So, make sure you know how to quickly recreate your working environment. Again, best practice is to use something like git with https://github.com or https://gitlab.com
Copyright by Lincoln Centre for Autonomous Systems
-
CMP3103
- Using the Docker Image
- Week 1
- Week 2
- Week 3
- Week 4
- Week 5: Start working towards Coursework 2425
- Week 6: Enhancement Week, no timetabled sessions
- Week 7 and beyond
- Using the real Limo Robot
