-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
28 lines (24 loc) · 965 Bytes
/
Dockerfile
File metadata and controls
28 lines (24 loc) · 965 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# build stage
FROM node:lts-alpine AS build-stage
WORKDIR /app
COPY package*.json ./
RUN npm install
COPY . .
RUN npm run build
# Production stage
FROM nginx:stable-alpine
COPY --from=build-stage /app/dist /usr/share/nginx/html
COPY docker/nginx/conf.d/default.conf /etc/nginx/conf.d/default.conf
COPY docker/config.js /usr/share/nginx/html/config.js
COPY docker/config.json /usr/share/nginx/html/config.json
# Copy and set up the entrypoint script
COPY docker-entrypoint.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
# Dynamic labels are defined from the goreleaser configuration ".goreleaser.yaml"
LABEL org.opencontainers.image.authors="Olivier Vernin<me@olblak.com>"
LABEL org.opencontainers.image.title="Udash-front"
LABEL org.opencontainers.image.description="The Udash Frontend"
LABEL org.opencontainers.image.source=https://github.com/updatecli/udash-front
EXPOSE 80
ENTRYPOINT ["/docker-entrypoint.sh"]
CMD ["nginx", "-g", "daemon off;"]