Skip to content

Commit

Permalink
Fix example for custom docker images with plugins instlled
Browse files Browse the repository at this point in the history
  • Loading branch information
thomascube committed Dec 5, 2021
1 parent f5798d3 commit cd5b1f3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 15 deletions.
20 changes: 6 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,32 +126,24 @@ docker build -t roundcubemail .
You can also create your own Docker image by extending from this image.

For instance, you could extend this image to add composer and install requirements for builtin plugins or even external plugins:

```Dockerfile
FROM roundcube/roundcubemail:latest

COPY --from=composer:2 /usr/bin/composer /usr/bin/composer

RUN set -ex; \
apt-get update; \
apt-get install -y --no-install-recommends \
git \
; \
\
mv /usr/src/roundcubemail/composer.json-dist /usr/src/roundcubemail/composer.json; \
\
composer \
--working-dir=/usr/src/roundcubemail/ \
--prefer-dist --prefer-stable \
--no-update --no-interaction \
--optimize-autoloader --apcu-autoloader \
--prefer-dist \
--prefer-stable \
--update-no-dev \
--no-interaction \
--optimize-autoloader \
require \
johndoh/contextmenu \
; \
composer \
--working-dir=/usr/src/roundcubemail/ \
--prefer-dist --no-dev \
--no-interaction \
--optimize-autoloader --apcu-autoloader \
update;

```
2 changes: 1 addition & 1 deletion examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ which is used to install plugins. You can add and activate plugins by executing
inside a running Roundcube container:

```
$ docker exec -it roundcubemail composer.phar require johndoh/contextmenu --update-no-dev
$ docker exec -it roundcubemail composer require johndoh/contextmenu --update-no-dev
```

If you have mounted the container's volume `/var/www/html` the plugins installed persist on your host system. Otherwise they need to be (re-)installed every time you update or restart the Roundcube container.
Expand Down

0 comments on commit cd5b1f3

Please sign in to comment.