Skip to content
This repository has been archived by the owner on Mar 17, 2023. It is now read-only.

Commit

Permalink
Merge pull request #15 from ph-ash/fix-docker-configuration
Browse files Browse the repository at this point in the history
Fix docker configuration and add missing dependencies
  • Loading branch information
cawolf committed Mar 27, 2019
2 parents fa0f725 + 67813a3 commit 45a86c0
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 2 deletions.
5 changes: 5 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,18 @@ RUN apk add --no-cache php7-fpm \
php7-dom \
php7-iconv \
php7-mbstring \
php7-openssl \
php7-session \
php7-tokenizer \
php7-zip \
php7-pecl-zmq \
php7-pecl-mongodb \
supervisor \
fcgi \
&& cp docker/*-fpm.conf /etc/php7/php-fpm.d/ \
&& php bin/console cache:warmup \
&& crontab /var/www/html/docker/crontab

EXPOSE 9000

ENTRYPOINT ["supervisord", "--configuration", "/var/www/html/docker/supervisord.conf"]
11 changes: 11 additions & 0 deletions docker/docker-fpm.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[global]
error_log = /proc/self/fd/2

[www]
; if we send this to /proc/self/fd/1, it never appears
access.log = /proc/self/fd/2

clear_env = no

; Ensure worker stdout and stderr are sent to the main error log.
catch_workers_output = yes
2 changes: 1 addition & 1 deletion docker/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ nodaemon=true
user=root

[program:php-fpm]
command=php-fpm
command=php-fpm7 -F
stderr_logfile = /dev/stderr
stderr_logfile_maxbytes=0
stdout_logfile = /dev/stdout
Expand Down
5 changes: 5 additions & 0 deletions docker/zz-docker-fpm.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[global]
daemonize = no

[www]
listen = 9000
4 changes: 3 additions & 1 deletion src/Service/Board/ZMQ/ClientService.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ public function send(string $message, Channel $channel): void

public function __destruct()
{
$this->socket->close();
if ($this->socket) {
$this->socket->close();
}
}
}

0 comments on commit 45a86c0

Please sign in to comment.