Installing XLab
1. Install Docker
WINDOWS USERS: please backup your data before installing Docker.
In order to be cross-platform, Xlab has been dockerized. The first step is thus to install Docker Engine.
Here is how it shoud look like if you are on Debian:
sudo apt-get update
sudo apt-get install ca-certificates curl gnupg lsb-release
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
You can then run a test container:
sudo docker run --rm hello-world
Add sudo privileges to docker:
sudo groupadd docker
sudo usermod -aG docker $USER
Log out, log in, and check that you can run docker without sudo:
docker run --rm hello-world
2. Pull the Xlab image
Pull the image from DockerHub:
docker pull xlabimage/xlab
It can take a few minutes.
Once it is done, let us rename the image:
docker image tag xlabimage/xlab xlab
3. Run an Xlab container
Check that you can run an Xlab container:
docker run -it --rm xlab
You should now be given a new prompt. It is bash running inside the container. You can look around
ls
and exit the container:
exit
Congratulations!
You can now used Xlab and compute your first example.