slashfan / docker-supervisor-php-workers

Starting point configuration for running (PHP) workers inside Docker containers with Supervisor.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Docker - Supervisor config for (PHP) workers

Starting point configuration for running (PHP) workers inside Docker containers with Supervisor and Supervisorctl to manage them.

What's inside ?

  • PHP-CLI based Docker image with Supervisor installed: located in docker/php/Dockerfile.
  • Supervisor global configuration: located in docker/php/conf/supervisord.conf.
  • Supervisor programs configuration: located in docker/php/conf/supervisord-programs.conf.

How to use

Start container(s)

$ docker-compose build --pull
$ docker-compose up --build

List worker(s)

$ docker-compose exec php_worker supervisorctl status

Stop all worker(s)

$ docker-compose exec php_worker supervisorctl stop all

Start all worker(s)

$ docker-compose exec php_worker supervisorctl start all

Restart all worker(s)

$ docker-compose exec php_worker supervisorctl restart all

Stop container(s)

$ docker-compose stop

Cleanup container(s)

$ docker-compose down --volumes --remove-orphans

About

Starting point configuration for running (PHP) workers inside Docker containers with Supervisor.

License:MIT License


Languages

Language:Makefile 58.3%Language:PHP 25.8%Language:Dockerfile 15.9%