Skip to content

Commit 4534626

Browse files
committed
switch from yarn to npm
npm can do everything we need and is one less dependency.
1 parent fc9e406 commit 4534626

File tree

7 files changed

+829
-299
lines changed

7 files changed

+829
-299
lines changed

Dockerfile

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,22 @@ FROM metacpan/metacpan-base:latest
22

33
ARG CPM_ARGS=--with-test
44

5+
ENV NO_UPDATE_NOTIFIER=1
6+
57
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
68

79
RUN curl -sL https://deb.nodesource.com/setup_18.x | bash \
8-
&& curl -sL https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \
9-
&& echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list \
1010
&& apt-get update \
11-
&& apt-get install -y -f --no-install-recommends libcmark-dev dumb-init nodejs yarn=1.19.2-1 \
11+
&& apt-get install -y -f --no-install-recommends libcmark-dev dumb-init nodejs \
1212
&& apt-get clean \
13-
&& rm -rf /var/lib/apt/lists/*
13+
&& npm install -g npm
14+
&& rm -rf /var/lib/apt/lists/* /root/.npm
1415

1516
COPY . /metacpan-web/
1617
WORKDIR /metacpan-web
1718

19+
RUN npm install --verbose && npm cache clean --force
20+
1821
RUN cpanm --notest App::cpm \
1922
&& cpm install -g Carton \
2023
&& useradd -m metacpan-web -g users \
@@ -25,8 +28,6 @@ RUN chown -R metacpan-web:users /metacpan-web
2528

2629
USER metacpan-web:users
2730

28-
RUN yarn install --verbose && yarn cache clean
29-
3031
EXPOSE 5001
3132

3233
# Runs "/usr/bin/dumb-init -- /my/script --with --args"

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ If you prefer not to use Docker, the following commands will get you started:
2424
## Installing Manually
2525

2626
carton install
27-
yarn install
27+
npm install
2828
export PATH="$(realpath ./node_modules/.bin):$PATH"
2929

3030
### Installing on macOS

metacpan_web.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ consumer_key = metacpan.dev
99
cookie_secret = seekrit
1010
consumer_secret = ClearAirTurbulence
1111
log4perl_file = log4perl.conf
12-
lessc_command = yarn -s run lessc
12+
lessc_command = npx lessc
1313

1414
mark_unauthorized_releases = 0
1515

0 commit comments

Comments
 (0)