Docker provides a consistent and isolated environment to build, run, and develop oasis without worrying about system dependencies. This guide walks you through setting up oasis using Docker, running it, and developing with it.
- Docker:https://docs.docker.com/engine/install/
- Docker Compose:https://docs.docker.com/compose/install/
Before starting the container, you need to navigate into the
.container folder and create a .env file with your own
API keys, so that these keys will be present in the environment variables of
the container, which will later be used by OASIS.
cd .container
# Create your own .env file by copying the example
cp .env.example .env
# Edit .env to add your API keys or custom settingsTo build and start the development container:
docker compose up -dThis will:
- Build the image oasis:localdev
- Start the container oasis-localdev
- Set up all necessary dependencies
After the build is complete, you can verify the list of images and all running containers.
# List all Docker images
docker images
# Check running containers
docker psOnce running, you can access the container like this:
docker compose exec oasis bashYou’ll now be inside the oasis dev environment.
From here, you can activate your virtual environment (if used) and run tests:
# Any other dev/test command
pytest
pre-commit run --all-filesYour local code is volume-mounted into the container. That means any changes you make inside the container are reflected in your local project folder — no need to worry about losing your work.
You can simply press Ctrl + D or use the exit command to exit the
container.
After exiting the container, under normal cases the container will still be running in the background. If you don't need the container anymore, you can stop and delete the container with the following command.
docker compose downFor users who only want to have a quick tryout on OASIS, we also provide the pre-built images on our GitHub Container Registry.
If you only want to try oasis without setting up the build: