Remove entrypoint

Signed-off-by: Antonis Kalipetis <akalipetis@gmail.com>
This commit is contained in:
Antonis Kalipetis 2016-12-15 18:26:24 +02:00
parent 6b6314227e
commit b2e257bf37
No known key found for this signature in database
GPG Key ID: 15691170DA0396BB
2 changed files with 2 additions and 11 deletions

View File

@ -10,8 +10,8 @@ RUN apt-get update \
WORKDIR /usr/src/app WORKDIR /usr/src/app
# Set an entrypoint, to automatically install node modules # Set an entrypoint, to automatically install node modules
COPY entrypoint.sh /entrypoint.sh ENTRYPOINT ["/bin/bash", "-c", "if [[ ! -d node_modules ]]; then npm install; fi; exec \"$@\";"]
ENTRYPOINT ["/entrypoint.sh"] CMD ["npm", "run", "dev"]
# First, install dependencies to improve layer caching # First, install dependencies to improve layer caching
COPY package.json /usr/src/app/ COPY package.json /usr/src/app/
@ -22,4 +22,3 @@ COPY . /usr/src/app
# Run the tests and build, to make sure everything is working nicely # Run the tests and build, to make sure everything is working nicely
RUN npm run test && npm run build RUN npm run test && npm run build
CMD ["npm", "run", "dev"]

View File

@ -1,8 +0,0 @@
#! /bin/bash
# Install Node modules, if the `node_modules` directory does not exist
if [[ ! -d node_modules ]]; then
npm install;
fi
exec "$@"