building docker image for easier install

pull/36/head
freezy 2019-10-09 17:11:51 +02:00
parent d90f73d318
commit 95e729b34c
No known key found for this signature in database
GPG Key ID: 4B1F485A37ABB3A9
2 changed files with 14 additions and 0 deletions

4
Dockerfile Normal file
View File

@ -0,0 +1,4 @@
FROM bash
COPY install-php-extensions /usr/bin/install-php-extensions
RUN chmod +x /usr/bin/install-php-extensions

View File

@ -23,6 +23,16 @@ RUN chmod uga+x /usr/local/bin/install-php-extensions && sync && \
install-php-extensions gd xdebug
```
Installation via COPY --from
```
FROM php:7.2-cli
COPY --from=docker-install-php-extensions /usr/bin/install-php-extensions /usr/bin/
RUN install-php-extensions gd xdebug
```
`install-php-extensions` will install all the required APT packages.
If you want to remove the APT development packages (which shouldn't be needed after the PHP extensions have been installed) and other no longer required packages, you can use the `--cleanup` option (**EXPERIMENTAL**):
```