signoz/frontend/Dockerfile
Prashant Shahi d22d1d1c3b
refactor(ports): 💥 avoid exposing unnecessary ports and update frontend port to 3301 (#679)
* refactor(compose-yaml): ♻️ avoid unused and unnecessary ports mapping from compose files

Signed-off-by: Prashant Shahi <prashant@signoz.io>

* refactor(frontend): 💥 change frontend port to 3301
BREAKING CHANGE:

Signed-off-by: Prashant Shahi <prashant@signoz.io>
2022-02-08 22:47:06 +05:30

37 lines
652 B
Docker

# stage1 as builder
FROM node:12.18.0 as builder
# Add Maintainer Info
LABEL maintainer="signoz"
ARG TARGETOS=linux
ARG TARGETARCH
WORKDIR /frontend
# copy the package.json to install dependencies
COPY package.json ./
# Install the dependencies and make the folder
RUN yarn install
COPY . .
# Build the project and copy the files
RUN yarn build
FROM nginx:1.18-alpine
#!/bin/sh
COPY conf/default.conf /etc/nginx/conf.d/default.conf
## Remove default nginx index page
RUN rm -rf /usr/share/nginx/html/*
# Copy from the stahg 1
COPY --from=builder /frontend/build /usr/share/nginx/html
EXPOSE 3301
ENTRYPOINT ["nginx", "-g", "daemon off;"]