Update documentation

This commit is contained in:
cytopia
2022-12-11 10:36:14 +01:00
parent ff61a450ac
commit be2e96d4a2
9 changed files with 605 additions and 249 deletions

View File

@@ -17,9 +17,131 @@ Tools |
:information_source: For details on how to generate modules see **[Abuser Documentation: Build your own image](../doc/abuser/README.md)**<br/>
### PHP Tools (`slim`)
### PHP Tools ([`prod`](flavours.md#prod))
The following PHP cli tools are available on the `slim` flavour:
The following PHP cli tools are available on the [`prod`](flavours.md#prod) flavour:
> :information_source: Click on any tool name to find out what they are
<table>
<tr>
<th>Tool</th>
<th>PHP 5.2</th>
<th>PHP 5.3</th>
<th>PHP 5.4</th>
<th>PHP 5.5</th>
<th>PHP 5.6</th>
<th>PHP 7.0</th>
<th>PHP 7.1</th>
<th>PHP 7.2</th>
<th>PHP 7.3</th>
<th>PHP 7.4</th>
<th>PHP 8.0</th>
<th>PHP 8.1</th>
<th>PHP 8.2</th>
</tr>
<tr>
<td><a target="_blank" href="https://linux.die.net/man/8/cron">Cron</a></td>
<td class="tool_prod_cron_5.2">✓</td>
<td class="tool_prod_cron_5.3">✓</td>
<td class="tool_prod_cron_5.4">✓</td>
<td class="tool_prod_cron_5.5">✓</td>
<td class="tool_prod_cron_5.6">✓</td>
<td class="tool_prod_cron_7.0">✓</td>
<td class="tool_prod_cron_7.1">✓</td>
<td class="tool_prod_cron_7.2">✓</td>
<td class="tool_prod_cron_7.3">✓</td>
<td class="tool_prod_cron_7.4">✓</td>
<td class="tool_prod_cron_8.0">✓</td>
<td class="tool_prod_cron_8.1">✓</td>
<td class="tool_prod_cron_8.2">✓</td>
</tr>
<tr>
<td><a target="_blank" href="http://www.postfix.org/">Postfix</a></td>
<td class="tool_prod_postfix_5.2">✓</td>
<td class="tool_prod_postfix_5.3">✓</td>
<td class="tool_prod_postfix_5.4">✓</td>
<td class="tool_prod_postfix_5.5">✓</td>
<td class="tool_prod_postfix_5.6">✓</td>
<td class="tool_prod_postfix_7.0">✓</td>
<td class="tool_prod_postfix_7.1">✓</td>
<td class="tool_prod_postfix_7.2">✓</td>
<td class="tool_prod_postfix_7.3">✓</td>
<td class="tool_prod_postfix_7.4">✓</td>
<td class="tool_prod_postfix_8.0">✓</td>
<td class="tool_prod_postfix_8.1">✓</td>
<td class="tool_prod_postfix_8.2">✓</td>
</tr>
<tr>
<td><a target="_blank" href="http://www.postfix.org/pcre_table.5.html">Postfix PCRE</a></td>
<td class="tool_prod_postfix_pcre_5.2">✓</td>
<td class="tool_prod_postfix_pcre_5.3">✓</td>
<td class="tool_prod_postfix_pcre_5.4">✓</td>
<td class="tool_prod_postfix_pcre_5.5">✓</td>
<td class="tool_prod_postfix_pcre_5.6">✓</td>
<td class="tool_prod_postfix_pcre_7.0">✓</td>
<td class="tool_prod_postfix_pcre_7.1">✓</td>
<td class="tool_prod_postfix_pcre_7.2">✓</td>
<td class="tool_prod_postfix_pcre_7.3">✓</td>
<td class="tool_prod_postfix_pcre_7.4">✓</td>
<td class="tool_prod_postfix_pcre_8.0">✓</td>
<td class="tool_prod_postfix_pcre_8.1">✓</td>
<td class="tool_prod_postfix_pcre_8.2">✓</td>
</tr>
<tr>
<td><a target="_blank" href="https://www.rsyslog.com/">Rsyslog</a></td>
<td class="tool_prod_rsyslog_5.2">✓</td>
<td class="tool_prod_rsyslog_5.3">✓</td>
<td class="tool_prod_rsyslog_5.4">✓</td>
<td class="tool_prod_rsyslog_5.5">✓</td>
<td class="tool_prod_rsyslog_5.6">✓</td>
<td class="tool_prod_rsyslog_7.0">✓</td>
<td class="tool_prod_rsyslog_7.1">✓</td>
<td class="tool_prod_rsyslog_7.2">✓</td>
<td class="tool_prod_rsyslog_7.3">✓</td>
<td class="tool_prod_rsyslog_7.4">✓</td>
<td class="tool_prod_rsyslog_8.0">✓</td>
<td class="tool_prod_rsyslog_8.1">✓</td>
<td class="tool_prod_rsyslog_8.2">✓</td>
</tr>
<tr>
<td><a target="_blank" href="http://www.dest-unreach.org/socat/">Socat</a></td>
<td class="tool_prod_socat_5.2">✓</td>
<td class="tool_prod_socat_5.3">✓</td>
<td class="tool_prod_socat_5.4">✓</td>
<td class="tool_prod_socat_5.5">✓</td>
<td class="tool_prod_socat_5.6">✓</td>
<td class="tool_prod_socat_7.0">✓</td>
<td class="tool_prod_socat_7.1">✓</td>
<td class="tool_prod_socat_7.2">✓</td>
<td class="tool_prod_socat_7.3">✓</td>
<td class="tool_prod_socat_7.4">✓</td>
<td class="tool_prod_socat_8.0">✓</td>
<td class="tool_prod_socat_8.1">✓</td>
<td class="tool_prod_socat_8.2">✓</td>
</tr>
<tr>
<td><a target="_blank" href="http://supervisord.org/">Supervisor</a></td>
<td class="tool_prod_supervisor_5.2">✓</td>
<td class="tool_prod_supervisor_5.3">✓</td>
<td class="tool_prod_supervisor_5.4">✓</td>
<td class="tool_prod_supervisor_5.5">✓</td>
<td class="tool_prod_supervisor_5.6">✓</td>
<td class="tool_prod_supervisor_7.0">✓</td>
<td class="tool_prod_supervisor_7.1">✓</td>
<td class="tool_prod_supervisor_7.2">✓</td>
<td class="tool_prod_supervisor_7.3">✓</td>
<td class="tool_prod_supervisor_7.4">✓</td>
<td class="tool_prod_supervisor_8.0">✓</td>
<td class="tool_prod_supervisor_8.1">✓</td>
<td class="tool_prod_supervisor_8.2">✓</td>
</tr>
</table>
### PHP Tools ([`slim`](flavours.md#slim))
Additionally to all of the `prod` tools shown above, the following PHP cli tools are available on the [`slim`](flavours.md#slim) flavour:
> :information_source: Click on any tool name to find out what they are
@@ -237,10 +359,9 @@ The following PHP cli tools are available on the `slim` flavour:
> :exclamation: **\[1\]** Not available on `arm64` Docker image.
### PHP Tools ([`work`](flavours.md#work))
### PHP Tools (`work`)
Additionally to all of the `slim` tools shown above, the following PHP cli tools are available on the `work` flavour:
Additionally to all of the `slim` tools shown above, the following PHP cli tools are available on the [`work`](flavours.md#work) flavour:
> :information_source: Click on any tool name to find out what they are

View File

@@ -17,7 +17,7 @@ Base Images
### Base Images
Have a look at the following Devilbox base images for which no official versions exist yet, but are required to serve as a foundation for this repository:
Have a look at the following Devilbox base images for which no official versions exist yet (as of the time of writing), but are required to serve as a foundation for this repository:
* [PHP-FPM 5.2](https://github.com/devilbox/docker-php-fpm-5.2)
* [PHP-FPM 5.3](https://github.com/devilbox/docker-php-fpm-5.3)

View File

@@ -17,98 +17,226 @@ Env Vars |
### Environment Variables
Have a look at the following table to see all supported environment variables for each Docker image flavour.
<table>
<thead>
<tr>
<th>Image</th>
<th>Env Variable</th>
<th>Type</th>
<th>Default</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td rowspan="3"><strong>base</strong><br/><br/><strong>mods</strong><br/><br/><strong>prod</strong><br/><br/><strong>slim</strong><br/><br/><strong>work</strong></td>
<td><code>DEBUG_ENTRYPOINT</code></td>
<td>int</td>
<td><code>0</code></td>
<td>Set debug level for startup.<br/><sub><code>0</code> Only warnings and errors are shown.<br/><code>1</code> All log messages are shown<br/><code>2</code> All log messages and executed commands are shown.</sub></td>
</tr>
<tr>
<td><code>NEW_UID</code></td>
<td>int</td>
<td><code>1000</code></td>
<td>Assign the PHP-FPM user a new <code>uid</code> in order to syncronize file system permissions with your host computer and the Docker container. You should use a value that matches your host systems local user.<br/><sub>(Type <code>id -u</code> for your uid).</sub></td>
</tr>
<tr>
<td><code>NEW_GID</code></td>
<td>int</td>
<td><code>1000</code></td>
<td>Assign the PHP-FPM group a new <code>gid</code> in order to syncronize file system permissions with your host computer and the Docker container. You should use a value that matches your host systems local group.<br/><sub>(Type <code>id -g</code> for your gid).</sub></td>
</tr>
<tr>
<td colspan="5"></td>
</tr>
<tr>
<td rowspan="6"><strong>prod</strong><br/><br/><strong>slim</strong><br/><br/><strong>work</strong></td>
<td><code>TIMEZONE</code></td>
<td>string</td>
<td><code>UTC</code></td>
<td>Set docker OS timezone as well as PHP timezone.<br/>(Example: <code>Europe/Berlin</code>)</td>
</tr>
<tr>
<td><code>DOCKER_LOGS</code></td>
<td>bool</td>
<td><code>1</code></td>
<td>By default all Docker images are configured to output their PHP-FPM access and error logs to stdout and stderr. Those which support it can change the behaviour to log into files inside the container. Their respective directories are available as volumes that can be mounted to the host computer. This feature might help developer who are more comfortable with tailing or searching through actual files instead of using docker logs.<br/><br/>Set this variable to <code>0</code> in order to enable logging to files. Log files are avilable under <code>/var/log/php/</code> which is also a docker volume that can be mounted locally.</td>
</tr>
<tr>
<td><code>ENABLE_MODULES</code></td>
<td>string</td>
<td><code>''</code></td>
<td>Comma separated list of PHP modules to enable, which are not enabled by default.<br/><strong>Example:</strong><br/><code>ENABLE_MODULES=blackfire, ioncube, psr, phalcon</code></td>
</tr>
<tr>
<td><code>DISABLE_MODULES</code></td>
<td>string</td>
<td><code>''</code></td>
<td>Comma separated list of PHP modules to disable.<br/><strong>Example:</strong><br/><code>DISABLE_MODULES=swoole,imagick</code></td>
</tr>
<tr>
<td><code>ENABLE_MAIL</code></td>
<td>bool</td>
<td><code>0</code></td>
<td>Start local postfix with or without email catch-all.<br/><code>0</code>: Postfix service disabled.<br/><code>1</code>: Postfix service started normally.<br/><code>2</code>: Postfix service started configured for local delivery and all mails sent (even to real domains) will be catched locally. No email will ever go out. They will all be stored in a local devilbox account.<br/>Value: <code>0</code>, <code>1</code> or <code>2</code></td>
</tr>
<tr>
<td><code>FORWARD_PORTS_TO_LOCALHOST</code></td>
<td>string</td>
<td></td>
<td>List of remote ports to forward to 127.0.0.1.<br/><strong>Format:</strong><br/><sub><code>&lt;local-port&gt;:&lt;remote-host&gt;:&lt;remote-port&gt;</code></sub><br/>You can separate multiple entries by comma.<br/><strong>Example:</strong><br/><sub><code>3306:mysqlhost:3306, 6379:192.0.1.1:6379</code></sub></td>
</tr>
<tr>
<td colspan="5"></td>
</tr>
<tr>
<td rowspan="3"><strong>slim</strong><br/><br/><strong>work</strong></td>
<td><code>MYSQL_BACKUP_USER</code></td>
<td>string</td>
<td><code>''</code></td>
<td>Username for mysql backups used for bundled <a href="https://mysqldump-secure.org" >mysqldump-secure</a></td>
</tr>
<tr>
<td><code>MYSQL_BACKUP_PASS</code></td>
<td>string</td>
<td><code>''</code></td>
<td>Password for mysql backups used for bundled <a href="https://mysqldump-secure.org" >mysqldump-secure</a></td>
</tr>
<tr>
<td><code>MYSQL_BACKUP_HOST</code></td>
<td>string</td>
<td><code>''</code></td>
<td>Hostname for mysql backups used for bundled <a href="https://mysqldump-secure.org" >mysqldump-secure</a></td>
</tr>
</tbody>
</table>
1. [Overview](#overview)
2. [`DEBUG_ENTRYPOINT`][lnk_env_debug]
3. [`NEW_UID`][lnk_env_uid]
4. [`NEW_GID`][lnk_env_gid]
5. [`TIMEZONE`][lnk_env_timezone]
6. [`DOCKER_LOGS`][lnk_env_logs]
7. [`ENABLE_MODULES`][lnk_env_enable_mods]
8. [`DISABLE_MODULES`][lnk_env_disable_mods]
9. [`ENABLE_MAIL`][lnk_env_enable_mail]
10. [`FORWARD_PORTS_TO_LOCALHOST`][lnk_env_forward]
11. [`MYSQL_BACKUP_USER`][lnk_env_backup_user]
12. [`MYSQL_BACKUP_PASS`][lnk_env_backup_pass]
13. [`MYSQL_BACKUP_HOST`][lnk_env_backup_host]
[lnk_env_debug]: #-debug_entrypoint
[lnk_env_uid]: #-new_uid
[lnk_env_gid]: #-new_gid
[lnk_env_timezone]: #-timezone
[lnk_env_logs]: #-docker_logs
[lnk_env_enable_mods]: #-enable_modules
[lnk_env_disable_mods]: #-disable_modules
[lnk_env_enable_mail]: #-enable_mail
[lnk_env_forward]: #-forward_ports_to_localhost
[lnk_env_backup_user]: #-mysql_backup_user
[lnk_env_backup_pass]: #-mysql_backup_pass
[lnk_env_backup_host]: #-mysql_backup_host
### Overview
The following table gives an overview about which environment variable is available to which flavour.
| Environment Variable | `base` | `mods` | `prod` | `slim` | `work` |
|------------------------------|--------|--------|--------|--------|--------|
| `DEBUG_ENTRYPOINT` | ✓ | ✓ | ✓ | ✓ | ✓ |
| `NEW_UID` | ✓ | ✓ | ✓ | ✓ | ✓ |
| `NEW_GID` | ✓ | ✓ | ✓ | ✓ | ✓ |
| `TIMEZONE` | | | ✓ | ✓ | ✓ |
| `DOCKER_LOGS` | | | ✓ | ✓ | ✓ |
| `ENABLE_MODULES` | | | ✓ | ✓ | ✓ |
| `DISABLE_MODULES` | | | ✓ | ✓ | ✓ |
| `ENABLE_MAIL` | | | ✓ | ✓ | ✓ |
| `FORWARD_PORTS_TO_LOCALHOST` | | | ✓ | ✓ | ✓ |
| `MYSQL_BACKUP_USER` | | | | ✓ | ✓ |
| `MYSQL_BACKUP_PASS` | | | | ✓ | ✓ |
| `MYSQL_BACKUP_HOST` | | | | ✓ | ✓ |
### ∑ `DEBUG_ENTRYPOINT`
This variable controls the debug level (verbosity) for the container startup. The more verbose, the more information is shown via docker logs during startup.
* **Var type:** `int`
* **Default:** `0`
* **Allowed:** `0`, `1`, `2`
When set to `0` (default), only errors and warnings are shown.
When set to `1`, all log messages are shown.
When set to `2`, all log messages and all commands that are being executed by the entrypoint script are shown.
### ∑ `NEW_UID`
This variable controls the user id of the php-fpm process.
* **Var type:** `int`
* **Default:** `1000`
* **Allowed:** any valid user id (use your local users' `uid`)
> **Backgrund:** The php-fpm docker image has a non-root user (and group) that the php-fpm process runs with. When one of your PHP scripts creates a file (cache, uploads, etc), it is being created with the user id and group id, the php-fpm process runs with. In order to make sure this is the same user id as your normal user locally on the host system, this env variable can be used to change the user id inside the container (during startup).
Why can't the php-fpm process run as root? It would then create files with root permissions and as those files are actually on your host system, you would require root permission to access/edit them again.
>
> You can read more about this topic here: [Syncronize file and folder Permissions](syncronize-file-permissions.md).
You want the PHP-FPM process to run with the same **user id** as the user on your host system.
What value should I set this to? Open up a terminal on your host system and type **`id -u`** to find out the user id of your local user.
### ∑ `NEW_GID`
This variable controls the group id of the php-fpm process.
* **Var type:** `int`
* **Default:** `1000`
* **Allowed:** any valid group id (use your local users' `gid`)
> **Background:** See the section in `NEW_UID`
You want the PHP-FPM process to run with the same **group id **as the user on your host system.
What value should I set this to? Open up a terminal on your host system and type **`id -g`** to find out the group id of your local user.
### ∑ `TIMEZONE`
This variable sets the timezone for the container as well as for the PHP-FPM process (via php.ini directives).
* **Var type:** `string`
* **Default:** `UTC`
* **Allowed:** any valid timezone (e.g.: `Europe/Berlin`)
### ∑ `DOCKER_LOGS`
This variable controls whether PHP access and error logs are written to a log file inside the container or shown via docker logs.
* **Var type:** `bool`
* **Default:** `1`
* **Allowed:** `0` or `1`
By default (value: `1`) all Docker images are configured to output their PHP-FPM access and error logs to stdout and stderr, which means it is shown by `docker logs` (or `docker-compose logs`).
If you want to log into files inside the container instead, change it to `0`. The respective log files are available as Docker volumes and can be mounted to your local file system so you can `cat`, `tail` or `grep` them for anything interesting.
### ∑ `ENABLE_MODULES`
Some PHP extensions are not enabled by default (e.g.: `blackfire`, `ioncube`, `swoole` and others). See [PHP modules](php-modules.md) to find out availalable modules and which are enabled/disabled by default. This variable explicitly enabled PHP modules during startup.
* **Var type:** comma separated `string` of modules to enable
* **Default:** ``
* **Allowed:** available modules as a commaa separated string
Example:
```bash
ENABLE_MODULES=swoole
ENABLE_MODULES=swoole,psr,phalcon
```
### ∑ `DISABLE_MODULES`
The PHP-FPM images come with lots of available and default-enabled PHP modules. You might not need all of them. This variable controls which of the modules you want to disable explicitly during startup.
**Note:** Not all modules can be disabled, as some of them are directly compiled into PHP itself. See [PHP modules](php-modules.md) to find out, which modules can be disabled.
* **Var type:** comma separated `string` of modules to disabled
* **Default:** ``
* **Allowed:** available modules as a commaa separated string
Example:
```bash
DISABLE_MODULES=imagick
DISABLE_MODULES=imagick,xdebug
```
### ∑ `ENABLE_MAIL`
This variable controls whether Postfix (smtpd) should run and how it should behave, when your PHP code sends emails. It can be configured to intercept any outbound send emails and keep them locally, so that you do not accidentally send mails out.
* **Var type:** `int`
* **Default:** `0`
* **Allowed:** `0`, `1` or `2`
By default (value: `0`), the Postfix service is disabled and not started locally inside the Docker container.
When set to `1`, the Postfix service is started normally with its out-of-the-box default configuration.
When set to `2`, the Postfix service is started and configured for local delivery. That means that all mails sent (even to real existing domains) are intercepted and catched locally. No email will ever leave the system. The emails are then stored in the `devilbox` users' mail file locally in the container. Its directory can also be mounted to your local file system to browse the mails that have been sent.
### ∑ `FORWARD_PORTS_TO_LOCALHOST`
This variable allows you to forward remote ports to `127.0.0.1` into the PHP-FPM docker container. This might be handy if you have another MySQL database container running and still want to be able to use `127.0.0.1` in your PHP configuration for the database host.
* **Var type:** `string`
* **Default:** ``
* **Allowed:** `<local-port>:<remote-host>:<remote-port>`
**Note:** You can forward multiple ports by comma separating the allowd forwarding string.
Forward a remote MySQL database locally to port 3307
```bash
# Remote MYSQL host/ip: mysqlhost
# Remote MYSQL port: 3306
# Local port to forward to: 3307
FORWARD_PORTS_TO_LOCALHOST=3307:mysqlhost:3306
```
Forward a remote MySQL and PostgreSQL locally to port 3307 and 5433
```bash
# Remote MYSQL host/ip: mysqlhost
# Remote MYSQL port: 3306
# Local port to forward to: 3307
# Remote PGSQL host/ip: pgsqlhost
# Remote PGSQL port: 5432
# Local port to forward to: 5433
FORWARD_PORTS_TO_LOCALHOST=3307:mysqlhost:3306, 5433:pgsqlhost:5432
```
### ∑ `MYSQL_BACKUP_USER`
You can just type `mysqldump-secure` inside the PHP-FPM container to easily backup your MySQL databases with one command. (See project: https://mysqldump-secure.org/).
In order to do so, you will need to pass a MySQL user to the PHP-FPM container, so it can auto-configure mysqldump-secure for you.
* **Var type:** `string`
* **Default:** ``
* **Allowed:** valid mysql user name
### ∑ `MYSQL_BACKUP_PASS`
You can just type `mysqldump-secure` inside the PHP-FPM container to easily backup your MySQL databases with one command. (See project: https://mysqldump-secure.org/).
In order to do so, you will need to pass a MySQL password to the PHP-FPM container, so it can auto-configure mysqldump-secure for you.
* **Var type:** `string`
* **Default:** ``
* **Allowed:** valid mysql password
### ∑ `MYSQL_BACKUP_HOST`
You can just type `mysqldump-secure` inside the PHP-FPM container to easily backup your MySQL databases with one command. (See project: https://mysqldump-secure.org/).
In order to do so, you will need to pass a MySQL hostname to the PHP-FPM container, so it can auto-configure mysqldump-secure for you.
* **Var type:** `string`
* **Default:** ``
* **Allowed:** valid hostname
**Note:** The hostname must be reachable from within the PHP-FPM container.

View File

@@ -17,65 +17,95 @@ Volumes |
### Docker Volumes
Have a look at the following table to see all offered volumes for each Docker image flavour.
1. [Overview](#overview)
2. [`/etc/php-custom.d/`][lnk_vol_php_custom]
3. [`/etc/php-fpm-custom.d/`][lnk_vol_php_fpm_custom]
4. [`/startup.1.d/`][lnk_vol_startup1]
5. [`/startup.2.d/`][lnk_vol_startup2]
6. [`/var/log/php/`][lnk_vol_log_php]
7. [`/var/mail/`][lnk_vol_mail]
8. [`/etc/supervisor/custom.d/`][lnk_vol_supervisor]
9. [`/etc/bashrc-devilbox.d/`][lnk_vol_bashrc]
10. [`/shared/backups/`][lnk_vol_backups]
11. [`/ca/`][lnk_vol_ca]
<table>
<thead>
<tr>
<th>Image</th>
<th width="240">Volumes</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td rowspan="8"><strong>prod</strong><br/><br/><strong>slim</strong><br/><br/><strong>work</strong></td>
<td><code>/etc/php-custom.d</code></td>
<td>Mount this directory into your host computer and add custom <code>\*.ini</code> files in order to alter php behaviour.</td>
</tr>
<tr>
<td><code>/etc/php-fpm-custom.d</code></td>
<td>Mount this directory into your host computer and add custom PHP-FPM <code>\*.conf</code> files in order to alter PHP-FPM behaviour.</td>
</tr>
<tr>
<td><code>/etc/php-modules.d</code></td>
<td>Mount this directory into your host computer and add custo <code>\*.so</code> files in order to add your php modules.<br/><br/><strong>Note:</strong>Your should then also provide a custom <code>\*.ini</code> file in order to actually load your custom provided module.</td>
</tr>
<tr>
<td><code>/startup.1.d</code></td>
<td>Any executable scripts ending by <code>\*.sh</code> found in this directory will be executed during startup. This is useful to supply additional commands (such as installing custom software) when the container starts up. (will run before <code>/startup.2.d</code>)</td>
</tr>
<tr>
<td><code>/startup.2.d</code></td>
<td>Any executable scripts ending by <code>\*.sh</code> found in this directory will be executed during startup. This is useful to supply additional commands (such as installing custom software) when the container starts up. (will run after <code>/startup.1.d</code>)</td>
</tr>
<tr>
<td><code>/var/log/php</code></td>
<td>When setting environment variable <code>DOCKER_LOGS</code> to <code>0</code>, log files will be available under this directory.</td>
</tr>
<tr>
<td><code>/var/mail</code></td>
<td>Emails caught be the postfix catch-all (<code>ENABLE_MAIL=2</code>) will be available in this directory.</td>
</tr>
<tr>
<td><code>/etc/supervisor/custom.d</code></td>
<td>Mount this directory into your host computer and add your own `*.conf` supervisor start-up files.<br/><br/>**Note:** Directory and file permission will be recursively set to this of `NEW_UID` and `NEW_GID`.</td>
</tr>
<tr>
<td colspan="3"></td>
</tr>
<tr>
<td rowspan="3"><strong>slim</strong><br/><br/><strong>work</strong></td>
<td><code>/etc/bashrc-devilbox.d</code></td>
<td>Mount this directory into your host computer and add custom configuration files for <code>bash</code> and other tools.</td>
</tr>
<tr>
<td><code>/shared/backups</code></td>
<td>Mount this directory into your host computer to access MySQL backups created by <a href="https://mysqldump-secure.org" >mysqldump-secure</a>.</td>
</tr>
<tr>
<td><code>/ca</code></td>
<td>Mount this directory into your host computer to bake any *.crt file that is located in there as a trusted SSL entity.</td>
</tr>
</tbody>
</table>
[lnk_vol_php_custom]: #-etcphp-customd
[lnk_vol_php_fpm_custom]: #-etcphp-fpm-customd
[lnk_vol_startup1]: #-startup1d
[lnk_vol_startup2]: #-startup2d
[lnk_vol_log_php]: #-varlogphp
[lnk_vol_mail]: #-varmail
[lnk_vol_supervisor]: #-etcsupervisorcustomd
[lnk_vol_bashrc]: #-etcbashrc-devilboxd
[lnk_vol_backups]: #-sharedbackups
[lnk_vol_ca]: #-ca
### Overview
The following table gives an overview about which volume is available to which flavour.
| Docker Volume | `base` | `mods` | `prod` | `slim` | `work` |
|-----------------------------|--------|--------|--------|--------|--------|
| `/etc/php-custom.d/` | | | ✓ | ✓ | ✓ |
| `/etc/php-fpm-custom.d/` | | | ✓ | ✓ | ✓ |
| `/startup.1.d/` | | | ✓ | ✓ | ✓ |
| `/startup.2.d/` | | | ✓ | ✓ | ✓ |
| `/var/log/php/` | | | ✓ | ✓ | ✓ |
| `/var/mail/` | | | ✓ | ✓ | ✓ |
| `/etc/supervisor/custom.d/` | | | ✓ | ✓ | ✓ |
| `/etc/bashrc-devilbox.d/` | | | | ✓ | ✓ |
| `/shared/backups/` | | | | ✓ | ✓ |
| `/ca/` | | | | ✓ | ✓ |
### 📂 `/etc/php-custom.d/`
Mount this directory into your host system and add custom PHP `*.ini` files in order to alter PHP behaviour.
### 📂 `/etc/php-fpm-custom.d/`
Mount this directory into your host system and add custom PHP-FPM `*.conf` files in order to alter PHP-FPM behaviour.
### 📂 `/startup.1.d/`
Any executable scripts ending by `*.sh` found in this directory will be executed during startup. This is useful to supply additional commands (such as installing custom software) when the container starts up. (will run before `/startup.2.d`).
### 📂 `/startup.2.d/`
Any executable scripts ending by `*.sh` found in this directory will be executed during startup. This is useful to supply additional commands (such as installing custom software) when the container starts up. (will run after `/startup.1.d`).
### 📂 `/var/log/php/`
When setting environment variable `DOCKER_LOGS` to `0`, PHP and PHP-FPM log files will be available in this directory.
### 📂 `/var/mail/`
Emails caught be the postfix catch-all (`ENABLE_MAIL=2`) will be available in this directory.
### 📂 `/etc/supervisor/custom.d/`
Mount this directory into your host computer and add your own `*.conf` supervisor start-up files.
**Note:** Directory and file permission will be recursively set to this of `NEW_UID` and `NEW_GID`.
### 📂 `/etc/bashrc-devilbox.d/`
Mount this directory into your host computer and add custom configuration files for `bash` and other tools.
### 📂 `/shared/backups/`
Mount this directory into your host computer to access MySQL backups created by [mysqldump-secure](https://mysqldump-secure.org/).
### 📂 `/ca/`
Mount this directory into your host computer to bake any `*.crt` file that is located in there as a trusted SSL entity.

View File

@@ -17,22 +17,22 @@ Flavours |
### Flavours
#### Image: base
#### base
Generic PHP-FPM base image. Use it to derive your own php-fpm docker image from it and add more extensions, tools and injectables.<br/><sub>(Does not offer any environment variables except for `NEW_UID` and `NEW_GID`)</sub>
#### Image: mods
#### mods
Generic PHP-FPM image with fully loaded extensions. Use it to derive your own php-fpm docker image from it and add more extensions, tools and injectables.<br/><sub>(Does not offer any environment variables except for `NEW_UID` and `NEW_GID`)</sub>
#### Image: prod
#### prod
Devilbox production image. This Docker image comes with many injectables, port-forwardings, mail-catch-all and user/group rewriting.
#### Image: slim
#### slim
Devilbox intranet-ready image. Similar to `prod`, but contains least subset of required cli tools to make the Devilbox intranet work.
#### Image: work
#### work
Devilbox development image. Same as prod, but comes with lots of locally installed tools to make development inside the container as convenient as possible. See [Integrated Development Environment](../README.md#integrated-development-environment) for more information about this.
Devilbox development image. Same as `slim`, but comes with lots of locally installed [tools](available-tools.md) to make development inside the container as convenient as possible. See [Integrated Development Environment](../README.md#integrated-development-environment) for more information about this.

View File

@@ -637,9 +637,9 @@ The following PHP modules are available on the `base` flavour:
### PHP Modules (`mods`, `prod` and `work`)
### PHP Modules (`mods`, `prod`, `slim` and `work`)
The following PHP modules are available on the `mods`, `prod` and `work` flavour:
The following PHP modules are available on the `mods`, `prod`, `slim` and `work` flavour:
> :information_source: Click on any extension name to find out what they are

View File

@@ -17,18 +17,18 @@ Versions |
### Available PHP versions
| Version | Architecture | Flavours |
|--------------------------|-------------------------|----------|
| :elephant: **`PHP 5.2`** | :computer: amd64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-5.2), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-5.2), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-5.2), :file_folder: [work](../Dockerfiles/work/Dockerfile-5.2) |
| :elephant: **`PHP 5.3`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-5.3), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-5.3), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-5.3), :file_folder: [work](../Dockerfiles/work/Dockerfile-5.3) |
| :elephant: **`PHP 5.4`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-5.4), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-5.4), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-5.4), :file_folder: [work](../Dockerfiles/work/Dockerfile-5.4) |
| :elephant: **`PHP 5.5`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-5.5), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-5.5), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-5.5), :file_folder: [work](../Dockerfiles/work/Dockerfile-5.5) |
| :elephant: **`PHP 5.6`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-5.6), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-5.6), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-5.6), :file_folder: [work](../Dockerfiles/work/Dockerfile-5.6) |
| :elephant: **`PHP 7.0`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-7.0), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-7.0), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-7.0), :file_folder: [work](../Dockerfiles/work/Dockerfile-7.0) |
| :elephant: **`PHP 7.1`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-7.1), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-7.1), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-7.1), :file_folder: [work](../Dockerfiles/work/Dockerfile-7.1) |
| :elephant: **`PHP 7.2`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-7.2), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-7.2), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-7.2), :file_folder: [work](../Dockerfiles/work/Dockerfile-7.2) |
| :elephant: **`PHP 7.3`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-7.3), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-7.3), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-7.3), :file_folder: [work](../Dockerfiles/work/Dockerfile-7.3) |
| :elephant: **`PHP 7.4`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-7.4), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-7.4), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-7.4), :file_folder: [work](../Dockerfiles/work/Dockerfile-7.4) |
| :elephant: **`PHP 8.0`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-8.0), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-8.0), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-8.0), :file_folder: [work](../Dockerfiles/work/Dockerfile-8.0) |
| :elephant: **`PHP 8.1`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-8.1), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-8.1), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-8.1), :file_folder: [work](../Dockerfiles/work/Dockerfile-8.1) |
| :elephant: **`PHP 8.2`** | :computer: amd64, arm64 | :file_folder: [base](../Dockerfiles/base/Dockerfile-8.2), :file_folder: [mods](../Dockerfiles/mods/Dockerfile-8.2), :file_folder: [prod](../Dockerfiles/prod/Dockerfile-8.2), :file_folder: [work](../Dockerfiles/work/Dockerfile-8.2) |
| Version | Architecture | Flavours |
|------------------|-----------------|----------|
| 🐘 **`PHP 5.2`** | 💻 amd64 | 📂 [base](../Dockerfiles/base/Dockerfile-5.2), 📂 [mods](../Dockerfiles/mods/Dockerfile-5.2), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.2), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.2), 📂 [work](../Dockerfiles/work/Dockerfile-5.2) |
| 🐘 **`PHP 5.3`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-5.3), 📂 [mods](../Dockerfiles/mods/Dockerfile-5.3), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.3), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.3), 📂 [work](../Dockerfiles/work/Dockerfile-5.3) |
| 🐘 **`PHP 5.4`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-5.4), 📂 [mods](../Dockerfiles/mods/Dockerfile-5.4), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.4), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.4), 📂 [work](../Dockerfiles/work/Dockerfile-5.4) |
| 🐘 **`PHP 5.5`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-5.5), 📂 [mods](../Dockerfiles/mods/Dockerfile-5.5), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.5), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.5), 📂 [work](../Dockerfiles/work/Dockerfile-5.5) |
| 🐘 **`PHP 5.6`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-5.6), 📂 [mods](../Dockerfiles/mods/Dockerfile-5.6), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.6), 📂 [slim](../Dockerfiles/slim/Dockerfile-5.6), 📂 [work](../Dockerfiles/work/Dockerfile-5.6) |
| 🐘 **`PHP 7.0`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-7.0), 📂 [mods](../Dockerfiles/mods/Dockerfile-7.0), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.0), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.0), 📂 [work](../Dockerfiles/work/Dockerfile-7.0) |
| 🐘 **`PHP 7.1`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-7.1), 📂 [mods](../Dockerfiles/mods/Dockerfile-7.1), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.1), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.1), 📂 [work](../Dockerfiles/work/Dockerfile-7.1) |
| 🐘 **`PHP 7.2`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-7.2), 📂 [mods](../Dockerfiles/mods/Dockerfile-7.2), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.2), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.2), 📂 [work](../Dockerfiles/work/Dockerfile-7.2) |
| 🐘 **`PHP 7.3`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-7.3), 📂 [mods](../Dockerfiles/mods/Dockerfile-7.3), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.3), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.3), 📂 [work](../Dockerfiles/work/Dockerfile-7.3) |
| 🐘 **`PHP 7.4`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-7.4), 📂 [mods](../Dockerfiles/mods/Dockerfile-7.4), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.4), 📂 [slim](../Dockerfiles/slim/Dockerfile-7.4), 📂 [work](../Dockerfiles/work/Dockerfile-7.4) |
| 🐘 **`PHP 8.0`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-8.0), 📂 [mods](../Dockerfiles/mods/Dockerfile-8.0), 📂 [slim](../Dockerfiles/slim/Dockerfile-8.0), 📂 [slim](../Dockerfiles/slim/Dockerfile-8.0), 📂 [work](../Dockerfiles/work/Dockerfile-8.0) |
| 🐘 **`PHP 8.1`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-8.1), 📂 [mods](../Dockerfiles/mods/Dockerfile-8.1), 📂 [slim](../Dockerfiles/slim/Dockerfile-8.1), 📂 [slim](../Dockerfiles/slim/Dockerfile-8.1), 📂 [work](../Dockerfiles/work/Dockerfile-8.1) |
| 🐘 **`PHP 8.2`** | 💻 amd64, arm64 | 📂 [base](../Dockerfiles/base/Dockerfile-8.2), 📂 [mods](../Dockerfiles/mods/Dockerfile-8.2), 📂 [slim](../Dockerfiles/slim/Dockerfile-8.2), 📂 [slim](../Dockerfiles/slim/Dockerfile-8.2), 📂 [work](../Dockerfiles/work/Dockerfile-8.2) |