Browse Source

working on distribution

Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
main
Stephan Richter 4 months ago
parent
commit
63a9fb89a4
  1. 13
      Dockerfile

13
Dockerfile

@ -4,20 +4,21 @@ RUN apk update \ @@ -4,20 +4,21 @@ RUN apk update \
RUN apk add bash clang-extra-tools git
ADD . /OpenCloudCal
WORKDIR /OpenCloudCal
RUN VERSION=$(clang-format --version | sed -e "s/.* //g") \
&& sed -i "s|clangFormat(.*).style|clangFormat(\"$VERSION\").style|g" build.gradle.kts \
&& ./gradlew jar
RUN VERSION=$(clang-format --version | sed -e "s/.* //g") && sed -i "s|clangFormat(.*).style|clangFormat(\"$VERSION\").style|g" build.gradle.kts
RUN ./gradlew build
RUN mv *app/build/distributions/*.zip /occ.zip
FROM alpine
RUN apk update \
&& apk add openjdk21-jre
&& apk add bash openjdk21-jre
COPY --from=build /occ.zip /opt/occ.zip
RUN cd /opt && unzip occ.zip && ls -al
RUN cd /opt \
&& unzip occ.zip \
&& mv de.srsoftware.cal.app occ \
&& rm *.zip
RUN adduser -S occ \
&& mkdir /data /home/occ/.config \
&& chown occ /data /home/occ/.config \
&& ln -s /data /home/occ/.config
USER occ
ENTRYPOINT java -jar /opt/lightoidc.jar
Loading…
Cancel
Save