From 957f2a5e73955b1ad8c7da86fed6a6c44054f34c Mon Sep 17 00:00:00 2001 From: Sergey Yarkov Date: Wed, 23 Mar 2022 21:02:34 +0300 Subject: [PATCH] fix: fixed entrypoint --- Dockerfile | 1 + docker-compose.yml | 11 ++--------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 279dd1b..5d4ed13 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,5 +16,6 @@ FROM base as production COPY --chown=node:node ./package*.json ./ RUN npm ci --production COPY --chown=node:node . . +RUN ["chmod", "+x", "./scripts/wait-for.sh"] EXPOSE 4000 CMD ["dumb-init", "node", "index.js"] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index c62ba5f..cd89160 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -32,15 +32,8 @@ services: volumes: - ./:/home/node/app - node_modules:/home/node/app/node_modules - command: - [ - './scripts/wait-for.sh', - 'postgres:5432', - '--', - 'dumb-init', - 'node', - 'index.js', - ] + entrypoint: ['./scripts/wait-for.sh', 'postgres:5432', '--'] + command: ['dumb-init', 'node', 'index.js'] networks: - app-network depends_on: