-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
54 lines (30 loc) · 911 Bytes
/
Dockerfile
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
FROM node:18-alpine as builder
LABEL version="0.5"
LABEL description="This is the base docker image for the Profitak Obedy frontend React app built with Waku."
WORKDIR /app
COPY package.json .
# COPY yarn.lock .
RUN yarn install
COPY public/ public/
COPY src/ src/
COPY components.json .
COPY tsconfig.json .
COPY tailwind.config.js .
COPY postcss.config.js .
RUN yarn build
# COPY httpd.conf dist/
RUN ls -l
RUN cd dist/ && ls -l
EXPOSE 4268
# Check if build succeeded
RUN [ -d "/app/dist" ] || exit 1
# FROM httpd:alpine
# WORKDIR /usr/local/apache2/htdocs/
# COPY --from=builder /app/dist .
# COPY --from=builder /app/dist/public .
# RUN ls -l
# COPY httpd.conf /usr/local/apache2/conf/
# COPY --from=builder /app/dist/public/index.html .
CMD ["yarn", "start"]
# Health check to verify application is running
# HEALTHCHECK --interval=30s CMD wget -qO- http://localhost:5000 || exit 1