From 36045f6b6bfd9f6b5ca6940c3ed27e676d31ed60 Mon Sep 17 00:00:00 2001 From: flifloo Date: Tue, 1 Feb 2022 09:13:46 +0100 Subject: [PATCH] Add docker-compose.yml file example and installation instruction in the README --- README.md | 43 ++++++++++++++++++++++++++++++++++++++++++- docker-compose.yml | 27 +++++++++++++++++++++++++++ 2 files changed, 69 insertions(+), 1 deletion(-) create mode 100644 docker-compose.yml diff --git a/README.md b/README.md index e280ffb..d072a1a 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,44 @@ # FusionDirectory Docker -Basic Docker image for FusionDirectory web server \ No newline at end of file +Basic Docker image for FusionDirectory web server + + +## Installation +You can use the [docker-compose.yml](./docker-compose.yml) example file. + +### Welcome +On the first run of FusionDirectory, you have to configure the application, go to the server, like [http://localhost:8080](http://localhost:8080). + +For the authentication, run this command with the `INSTALLATION_TOKEN` given at the bottom of the first page: + +```bash +docker exec fusiondirectory bash -c 'echo -n INSTALLATION_TOKEN /var/cache/fusiondirectory/fusiondirectory.auth' +``` + +### Language setup & Installation check +Select a language and confirm that all the installation check is Ok. + +### LDAP setup +On the LDAP connection setup, you have to fill: +* `Connection URI` with the LDAP URI, example: `ldap://openldap:389` +* `Base` with the LDPA base DN, example: `dc=example,dc=org` +* `Admin DN` with the DN of the LDAP admin, example: `cn=admin` +* `Admin password`: with the password of the LDAP admin , example: `example` +Refresh the status and if it's succeeded go to the next page. + +### FusionDirectory configuration +You can customize FusionDirectory here, you don't have to, the default values are good. + +### LDAP inspection +Run every LDAP migration and create the FusionDirectory's admin user. + +You can go to the next page when every check is Ok/green. + +### Finish +You can download the configuration file and place it into the FusionDirectory etc volume as `fusiondirectory.conf` and run: + +``` bash +docker exec -it fusiondirectory fusiondirectory-setup --check-config +``` + +Now you can press next, you will be redirected to the login page. You can use the FusionDirectory's admin user credentials created earlier to login. diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..c483b3b --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,27 @@ +version: "3" + +services: + fusiondirectory: + container_name: fusiondirectory + image: registry.git.flifloo.fr/flifloo/fusiondirectory-docker:latest + ports: + - 8080:80 + volumes: + - "./fusiondirectory/etc:/etc/fusiondirectory" + restart: always + + openldap: + hostname: ldap.example.fr + image: registry.git.flifloo.fr/flifloo/openldap-fd-docker:latest + container_name: openldap + environment: + LDPA_ADMINPWD: example + LDAP_DOMAIN: example.org + LDAP_ORGANIZATION: Exemple Org + ports: + - 389:389 + volumes: + - "./openldap/data:/var/lib/ldap" + - "./openldap/conf:/etc/ldap/slapd.d" + restart: always +