1
- FROM gradle:jdk21
1
+ FROM gradle:jdk21 AS build
2
2
3
3
USER root
4
4
RUN apt-get update && apt-get upgrade -y && apt-get install -y --no-install-recommends git ca-certificates
@@ -13,14 +13,14 @@ RUN mv -v /cruise-control/cruise-control/build/libs/cruise-control-*.jar \
13
13
RUN mv -v /cruise-control/cruise-control/build/dependant-libs/cruise-control-metrics-reporter-*.jar \
14
14
/cruise-control/cruise-control/build/dependant-libs/cruise-control-metrics-reporter.jar
15
15
16
- FROM node:18-buster
16
+ FROM node:10 AS ui
17
17
RUN mkdir /src && cd /src && git clone https://github.com/amuraru/cruise-control-ui.git
18
18
WORKDIR /src/cruise-control-ui
19
19
RUN git fetch origin
20
20
RUN git checkout master
21
21
RUN git pull
22
22
RUN git rev-parse HEAD
23
- RUN npm install
23
+ RUN npm install --verbose --timeout=600000
24
24
RUN npm run build
25
25
26
26
# backported from https://github.com/docker-library/openjdk/blob/master/18/jdk/slim-bullseye/Dockerfile
@@ -110,12 +110,12 @@ RUN set -eux; \
110
110
java --version
111
111
112
112
RUN mkdir -p /opt/cruise-control /opt/cruise-control/cruise-control-ui
113
- COPY --from=0 /cruise-control/cruise-control/build/libs/cruise-control.jar /opt/cruise-control/cruise-control/build/libs/cruise-control.jar
114
- COPY --from=0 /cruise-control/config /opt/cruise-control/config
115
- COPY --from=0 /cruise-control/kafka-cruise-control-start.sh /opt/cruise-control/
116
- COPY --from=0 /cruise-control/cruise-control/build/dependant-libs /opt/cruise-control/cruise-control/build/dependant-libs
113
+ COPY --from=build /cruise-control/cruise-control/build/libs/cruise-control.jar /opt/cruise-control/cruise-control/build/libs/cruise-control.jar
114
+ COPY --from=build /cruise-control/config /opt/cruise-control/config
115
+ COPY --from=build /cruise-control/kafka-cruise-control-start.sh /opt/cruise-control/
116
+ COPY --from=build /cruise-control/cruise-control/build/dependant-libs /opt/cruise-control/cruise-control/build/dependant-libs
117
117
COPY docker/opt/cruise-control /opt/cruise-control/
118
- COPY --from=1 /src/cruise-control-ui/dist /opt/cruise-control/cruise-control-ui/dist
118
+ COPY --from=ui /src/cruise-control-ui/dist /opt/cruise-control/cruise-control-ui/dist
119
119
RUN echo "local,localhost,/kafkacruisecontrol" > /opt/cruise-control/cruise-control-ui/dist/static/config.csv
120
120
121
121
EXPOSE 8090
0 commit comments