Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/wandersonwhcr/docker-nginx-php-fpm

Docker (+ Traefik) + NGINX + PHP-FPM = The Right Way
https://github.com/wandersonwhcr/docker-nginx-php-fpm

docker docker-compose kubernetes nginx php-fpm slim-framework traefik

Last synced: 8 days ago
JSON representation

Docker (+ Traefik) + NGINX + PHP-FPM = The Right Way

Awesome Lists containing this project

README

        

# docker-nginx-php-fpm

Docker (+ Traefik) + NGINX + PHP-FPM = The Right Way

## Run

```
docker-compose up --detach
docker-compose exec php-fpm composer install

docker-compose up --detach \
--scale nginx=3 \
--scale php-fpm=3
```

## Production

```
docker build . --tag wandersonwhcr/hello
```

## Deployment

* Docker

```
docker network create hello

docker run \
--detach \
--hostname php-fpm \
--name hello_php-fpm \
--network hello \
wandersonwhcr/hello

docker run \
--detach \
--hostname nginx \
--name hello_nginx \
--network hello \
--volume `pwd`/docker-compose/nginx/templates:/etc/nginx/templates \
nginx:1.19
```

* Kubernetes

```
kubectl apply --filename ./kubernetes/ --recursive
```

## References

* [renatomefi/php-fpm-healthcheck](https://github.com/renatomefi/php-fpm-healthcheck) POSIX sh Script to HealthCheck PHP-FPM