Getting started
We provide a docker-compose.yml
file that starts Userli, Dovecot and MariaDB to set up a development environment.
Requirements
docker-compose
orpodman-compose
yarn
(oryarnpkg
on Ubuntu or Debian based systems)composer
make
Info
If you don't have podman or docker installed, you can find the installation instructions on the podman website or the docker website.
Set up
Start the containers:
podman compose up -d
docker compose up -d
Info
This command will initiate building the containers on first run. Append --build
to always force a full rebuild
Install PHP dependencies, run composer scripts and update JavaScript assets:
make assets
Tip
See the contents of the Makefile
if you are interested what each make
-command does.
Initialize the database:
podman compose exec userli bin/console doctrine:schema:create
docker compose exec userli bin/console doctrine:schema:create
Install sample data:
podman compose exec userli bin/console doctrine:fixtures:load
docker compose exec userli bin/console doctrine:fixtures:load
Info
The doctrine:fixtures:load
command will create four new accounts with corresponding roles (admin
, user
, support
, suspicious
) as well as some random aliases and vouchers. The domain for all accounts is "example.org" and the password is "password".
If you want to see more details about how the users are created, see src/DataFixtures
.
Open your browser and go to http://localhost:8000
Troubleshooting
On systems with SELinux enabled, the webserver might throw an error due to broken filesystem permissions.
To fix this, create docker-compose.override.yml
in the root directory with following content:
---
services:
userli:
security_opt:
- label=disable
dovecot:
security_opt:
- label=disable