Skip to content

Commit

Permalink
Merge pull request #19 from wanteddev/throttling-and-registry
Browse files Browse the repository at this point in the history
Improving Dockerfile caching
  • Loading branch information
avasconcelos114 authored Mar 23, 2021
2 parents 0405995 + 9b4bcc4 commit 30ed897
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
architecture.svg
ecosystem.config.js
4 changes: 0 additions & 4 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ jobs:
name: Build Lighthouse Image
runs-on: ubuntu-18.04

strategy:
matrix:
node-version: [15.x]

steps:
- uses: actions/checkout@v2
with:
Expand Down
11 changes: 8 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,14 @@ RUN apt-get update \
&& wget --quiet https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh -O /usr/sbin/wait-for-it.sh \
&& chmod +x /usr/sbin/wait-for-it.sh

COPY . /home/app
WORKDIR /home/app

RUN npm install
RUN npm install -g pm2
COPY ./package.json /home/app/package.json
COPY ./yarn.lock /home/app/yarn.lock

RUN yarn --frozen-lockfile
RUN yarn global add pm2

COPY . /home/app

CMD [ "node", "src/index.js" ]

0 comments on commit 30ed897

Please sign in to comment.