2020-11-10 16:52:52 +00:00
|
|
|
# Demo and development
|
|
|
|
|
2022-03-18 16:44:58 +00:00
|
|
|
To check out how canaille looks like, or to start contributions, just run the demo:
|
|
|
|
- with `docker-compose up` to install and run it in preconfigured docker containers
|
|
|
|
- or with `./run.sh` to install it natively in a virtual environment and run it locally!
|
2021-04-07 07:16:26 +00:00
|
|
|
|
2022-03-18 16:44:58 +00:00
|
|
|
# Prerequisites for native demo installation
|
2021-04-07 07:16:26 +00:00
|
|
|
|
|
|
|
You need to have `OpenLDAP` somewhere in your system.
|
|
|
|
|
|
|
|
You can either:
|
|
|
|
- install it with your distro packages *(for instance `sudo apt install slapd ldap-utils` with Ubuntu)*.
|
|
|
|
it is not required to launch the system ldap service.
|
|
|
|
- have `docker` plus `docker-compose` installed on your system, the `./run.sh` script will download and
|
2022-03-18 16:44:58 +00:00
|
|
|
run an OpenLDAP image.
|
2021-04-07 07:16:26 +00:00
|
|
|
|
|
|
|
canaille depends on [python-ldap](https://github.com/python-ldap/python-ldap), and this package needs
|
|
|
|
some headers to be installed on your system to be built. For instance on Ubuntu you can install this:
|
|
|
|
`sudo apt install libsasl2-dev python-dev libldap2-dev libssl-dev`. More info
|
|
|
|
[on this SO ticket](https://stackoverflow.com/questions/4768446/i-cant-install-python-ldap).
|
|
|
|
|
|
|
|
## Apparmor
|
|
|
|
|
|
|
|
On Ubuntu systems, apparmor prevents *slapd* from accessing files that are not in the standard
|
|
|
|
OpenLDAP installation. This may result in canaille being impossible to launch. To fix this you
|
|
|
|
can pass slapd in complain mode:
|
|
|
|
|
|
|
|
```bash
|
|
|
|
sudo apt install --yes apparmor-utils
|
|
|
|
sudo aa-complain /usr/sbin/slapd
|
|
|
|
```
|
|
|
|
|
|
|
|
# Run the demo
|
2020-11-10 16:52:52 +00:00
|
|
|
|
|
|
|
Then you have access to:
|
|
|
|
|
2022-03-18 16:44:58 +00:00
|
|
|
- A canaille server at http://localhost:5000
|
|
|
|
- A dummy client at http://localhost:5001
|
2023-02-14 20:55:46 +00:00
|
|
|
- Another dummy client at http://localhost:5002, for which consent is already granted for users
|
2020-11-10 16:52:52 +00:00
|
|
|
|
|
|
|
The canaille server has some default users:
|
|
|
|
|
2020-11-12 08:30:39 +00:00
|
|
|
- A regular user which login and password are **user**;
|
|
|
|
- A moderator user which login and password are **moderator**;
|
2022-03-18 16:44:58 +00:00
|
|
|
- An admin user which login and password are **admin**.
|
|
|
|
- A new user which login is **james**. This user has no password yet,
|
|
|
|
and his first attempt to log-in would result in sending a password initialization
|
|
|
|
email (if a smtp server is configurated).
|