Setting up a dev environment has some extra complexity due to the mono-repo design.
- Install poetry:
python -m pip install poetry. This is what we use to manage the packages, and allows you to set up virtual python environments easier.
- Build the base environment. From within the kanidm_rlm_python directory, run:
- Install the
poetry run python -m pip install ../pykanidm
- Start editing!
Most IDEs will be happier if you open the
pykanidm directories as the base you are working from, rather than the
kanidm repository root, so they can auto-load integrations etc.
From the root directory of the Kanidm repository:
- Build the container - this'll give you a container image called
kanidm/radiuswith the tag
- Once the process has completed, check the container exists in your docker environment:
➜ docker image ls kanidm/radius REPOSITORY TAG IMAGE ID CREATED SIZE kanidm/radius devel 5dabe894134c About a minute ago 622MB
Note: If you're just looking to play with a pre-built container, images are also automatically built based on the development branch and available at
- Generate some self-signed certificates by running the script - just hit enter on all the prompts if you don't want to customise them. This'll put the files in
- Run the container:
cd kanidm_rlm_python && ./run_radius_container.sh
You can pass the following environment variables to
run_radius_container.sh to set other options:
- IMAGE: an alternative image such as
- CONFIG_FILE: mount your own config file
IMAGE=ghcr.io/kanidm/radius:devel \ CONFIG_FILE=~/.config/kanidm \ ./run_radius_container.sh
Authentication can be tested through the client.localhost Network Access Server (NAS) configuration with:
docker exec -i -t radiusd radtest \ <username> badpassword \ 127.0.0.1 10 testing123 docker exec -i -t radiusd radtest \ <username> <radius show_secret value here> \ 127.0.0.1 10 testing123