Skip to content

Commit

Permalink
Ensure Restart with Existing PID (#111)
Browse files Browse the repository at this point in the history
* Use specific PID within container
  • Loading branch information
Owajigbanam Ogbuluijah authored and phallstrom committed Oct 16, 2019
1 parent 737619c commit 3f06d0c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
FROM ruby:2.5.7-alpine

ENV APP_DIR /usr/src/app

RUN apk add --update --no-cache \
build-base \
less \
Expand All @@ -11,12 +13,12 @@ RUN apk add --update --no-cache \
tini \
tzdata

WORKDIR /usr/src/app
WORKDIR $APP_DIR

COPY . ./

EXPOSE 3000

ENTRYPOINT ["/usr/src/app/bin/docker-entrypoint.sh"]

CMD ["bundle", "exec", "rails", "s", "-b", "0.0.0.0", "-p", "3000"]
CMD ["bundle", "exec", "rails", "s", "-b", "0.0.0.0", "-p", "3000", "-P", "/tmp/rails_server.pid"]

0 comments on commit 3f06d0c

Please sign in to comment.