デプロイで使用するdockerFileのnodeのバージョンを開発環境と合わせる

This commit is contained in:
saito.k 2023-09-13 15:56:35 +09:00
parent bdbb0dfe5d
commit 8c8362150a

View File

@ -1,14 +1,14 @@
FROM node:18.13.0-buster AS build-container
FROM node:18.17.1-buster AS build-container
WORKDIR /app
RUN mkdir dictation_server
COPY dictation_server/ dictation_server/
RUN npm install --force -g n && n 18.13.0 \
RUN npm install --force -g n && n 18.17.1 \
&& cd dictation_server \
&& npm ci \
&& npm run build \
&& cd ..
FROM node:18.13.0-alpine
FROM node:18.17.1-alpine
RUN apk --no-cache add tzdata \
&& cp /usr/share/zoneinfo/Asia/Tokyo /etc/localtime \
&& apk del tzdata \