Skip to content

Commit

Permalink
Upgrade to Node 20
Browse files Browse the repository at this point in the history
Use the new nodesource-recommended means of installing node, which
fixes the problems of npm not being found at build time
  • Loading branch information
drewbrew committed Oct 5, 2023
1 parent 08d80ac commit 4b5549e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 353 deletions.
9 changes: 8 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,18 @@ ENV PYTHONUNBUFFERED 1
RUN pip install pipenv
RUN pip install --upgrade pip setuptools wheel

RUN apt-get update
RUN apt -y dist-upgrade
RUN apt-get install -y ca-certificates curl gnupg
RUN mkdir -p /etc/apt/keyrings
RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg

# Adds our application code to the image
COPY . /code
WORKDIR /code

RUN bash /code/setup_node_16.sh
ENV NODE_MAJOR 20
RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
RUN apt-get update && apt-get -y dist-upgrade && apt-get -y install libmemcached-dev nodejs

# the version of node-sass that tailwind uses doesn't work with npm 5.x under node 10.x, which the debian docker image gives us
Expand Down
352 changes: 0 additions & 352 deletions setup_node_16.sh

This file was deleted.

0 comments on commit 4b5549e

Please sign in to comment.