Skip to content

Alternative PHP Docker repository with modification for out-of-the-box ready to use image

License

Notifications You must be signed in to change notification settings

eru123/docker-php

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

docker-php

For complete list of tags see Docker Hub.
For Documentation please refer to PHP official repo.

Added Features

  • Composer installed
  • .htaccess enabled
  • TZ env
  • HOST_ID and HOST_GID env for permission issues related to cross-container volume mounting (e.g. sftp and ssh containers)
  • COMPOSER_DIR and COMPOSER_DIRS env for composer install at startup, to fix overwriting of vendor directory when mounting a volume
  • Pre-installed PHP extensions
    • mysqli
    • pdo
    • pdo_mysql
    • zip
    • intl
    • opcache
    • xml

Environment variables (Optional)

Docker Environment Description
TZ Set the System Timezone
PWD The Container Workdir (/var/www/html)
HOST_ID The Container User ID
HOST_GID The Container Group ID
INI_ENV Use development or production .ini file (default to production)
COMPOSER_DIR Composer install directory, can be absolute or relative to PWD
COMPOSER_DIRS Composer install directories separated by space, can be absolute or relative to PWD