-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathDockerfile
32 lines (20 loc) · 899 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
FROM registry.access.redhat.com/ubi8/ubi:8.10-1184 as builder
RUN yum -y module enable nodejs:18
RUN dnf install npm patch -y
RUN npm install yarn -g
RUN mkdir /build
WORKDIR /build
COPY locales/ locales/
COPY tsconfig.json webpack.config.mjs console-extensions.json package.json sdk.patch ./
RUN yarn install
#RUN patch node_modules/\@openshift-console/dynamic-plugin-sdk/lib/webpack/ConsoleAssetPlugin.js sdk.patch
COPY src/ src/
RUN yarn build
FROM registry.access.redhat.com/ubi8/ubi-minimal:8.10-1179
ENV NGINX_CONFIGURATION_PATH=/etc/nginx/nginx.conf
RUN microdnf update && microdnf module enable nginx:1.22 && microdnf install nginx
ADD ./nginx.conf "${NGINX_CONFIGURATION_PATH}"
COPY --from=builder /build/dist /opt/clowder-plugin
COPY --from=builder /build/locales/ /opt/clowder-plugin/locales/
# Run script uses standard ways to run the application
CMD nginx -g "daemon off;"