live-server/Dockerfile

21 lines
765 B
Docker
Raw Normal View History

2023-12-05 16:24:43 +01:00
# Use an official Node runtime as a parent image
FROM node:20
# Set the working directory in the container
WORKDIR /usr/src/app
# Copy the package.json and yarn.lock (or package-lock.json)
COPY package*.json ./
COPY yarn.lock ./
# Install any needed packages specified in package.json
RUN yarn install
# Bundle your app's source code inside the Docker container
COPY . .
# Your app binds to port 80 so you'll use the EXPOSE instruction to have it mapped by the docker daemon
2023-12-06 07:55:26 +01:00
EXPOSE 8081
2023-12-05 16:24:43 +01:00
2023-12-05 18:09:37 +01:00
# Define the command to run your app using CMD which defines your runtime
2023-12-06 07:55:26 +01:00
CMD ["yarn", "run", "live-server", "--no-browser", "--port=8081", "--ignore='*'", "--entry-file=spa.html", "--no-css-inject", "--proxy=/api:http://tibi-server:8080/api/v1/_/einfo_test", "frontend"]