Add plugins support

This commit is contained in:
Ethanell 2023-04-18 20:13:53 +02:00
parent 36045f6b6b
commit dec8e3626a
3 changed files with 17 additions and 2 deletions

View file

@ -1,5 +1,5 @@
FROM debian:bullseye-slim FROM debian:bullseye-slim
RUN apt-get update && apt install --no-install-recommends -y php-fpm nginx fusiondirectory fusiondirectory-plugin-mail RUN apt-get update && apt-get install --no-install-recommends -y php-fpm nginx fusiondirectory
RUN mkdir /run/php && rm /etc/nginx/sites-enabled/default /etc/nginx/sites-available/default RUN mkdir /run/php && rm /etc/nginx/sites-enabled/default /etc/nginx/sites-available/default
COPY nginx-fusiondirectory.conf /etc/nginx/conf.d/fusiondirectory.conf COPY nginx-fusiondirectory.conf /etc/nginx/conf.d/fusiondirectory.conf
COPY fusiondirectory.conf /usr/share/doc/fusiondirectory/fusiondirectory.conf COPY fusiondirectory.conf /usr/share/doc/fusiondirectory/fusiondirectory.conf

View file

@ -42,3 +42,9 @@ 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. 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.
## Environment variables
| Variable | Value |
|:-------------------:|:------------------------------------------------------------------------------------:|
| `FD_PLUGINS` | Space separated list of plugins name |

View file

@ -1,4 +1,13 @@
#!/bin/bash #!/bin/bash
if [ -n "$FD_PLUGINS" ]; then
apt-get update
plugins=()
for plugin in $FD_PLUGINS; do
plugins+=("fusiondirectory-plugin-$plugin")
done
apt-get install -yy "${plugins[@]}"
fi
php-fpm7.4 php-fpm7.4
nginx -g 'daemon off;' nginx -g 'daemon off;'