Sign inSign up

itdogsoftware/nginx-php-fpm

By itdogsoftware

Updated 9 months ago

php-fpm 8.4.16, nginx, composer, node 18 for development purpose.

Image
Languages & frameworks
Developer tools
Web servers
0

3.4K

itdogsoftware/nginx-php-fpm repository overview

This image use supervisord to maintain php-fpm & nginx, pre-install composer & node 18.

Breaking change in v1.2.1. Recommend to use exact tag and avoid using latest.

As the image is recommended to run in non privilege mode.

It is required to mount an empty folder for /var/cache/nginx & /sock.

Customize your nginx.conf to match your application and mount it to /etc/nginx/nginx.conf accordingly.

    server {
      error_log /dev/null;
      access_log /dev/null;
      listen 8080 default_server;
      index index.php index.html;
      # Set nginx to serve files from the shared volume!
      root /var/www/html/public;
      server_name _;
      location / {
        try_files $uri $uri/ /index.php?$query_string;
      }
      # /sock is a shared volume with php-fpm service
      location ~ \.php$ {
        try_files $uri =404;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_pass unix:/sock/php-fpm.sock;
        fastcgi_index index.php;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PATH_INFO $fastcgi_path_info;
      }
    }

Tag summary

Content type

Image

Digest

sha256:f0d921c46

Size

306.8 MB

Last updated

9 months ago

docker pull itdogsoftware/nginx-php-fpm