Skip to content

Commit

Permalink
fix(sigterm): add missing exec in application.sh and missing extensio…
Browse files Browse the repository at this point in the history
…n pcntl in docker image (refs #59)
  • Loading branch information
mborne committed Nov 16, 2023
1 parent a068f70 commit 772c606
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ FROM composer:2.3 as vendor
RUN mkdir -p /opt/validator-api
WORKDIR /opt/validator-api
COPY composer.json .
RUN composer install --no-scripts --prefer-dist
RUN composer install --no-scripts --prefer-dist --ignore-platform-req=ext-pcntl

#----------------------------------------------------------------------
# Create base layer for dev and production
Expand Down Expand Up @@ -49,7 +49,7 @@ COPY .docker/php.ini /usr/local/etc/php/conf.d/app.ini
RUN apt-get update -qq \
&& apt-get install -y postgresql-client libpq-dev libzip-dev \
&& docker-php-ext-configure pgsql -with-pgsql=/usr/local/pgsql \
&& docker-php-ext-install opcache pdo pdo_pgsql pgsql zip \
&& docker-php-ext-install opcache pdo pdo_pgsql pgsql zip pcntl \
&& rm -rf /var/lib/apt/lists/*

#----------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion .docker/application.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ run(){
}

backend(){
bash loop-validate.sh
exec bash loop-validate.sh
}

test(){
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"ext-ctype": "*",
"ext-iconv": "*",
"ext-zip": "*",
"ext-pcntl": "*",
"composer/package-versions-deprecated": "^1.11",
"doctrine/annotations": "^1.10",
"doctrine/doctrine-bundle": "^2.1",
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ services:
#-----------------------------------------------------------------------
backend:
image: ignf/validator-api:master-dev
command: ["/bin/bash","loop-validate.sh"]
command: [".docker/application.sh","backend"]
environment:
- HTTP_PROXY=${HTTP_PROXY}
- HTTPS_PROXY=${HTTPS_PROXY}
Expand Down

0 comments on commit 772c606

Please sign in to comment.