Add Dockerfile to dockerize build of site.
This commit is contained in:
parent
a25162dfa6
commit
fc82c1a9ec
18
Dockerfile
Normal file
18
Dockerfile
Normal file
@ -0,0 +1,18 @@
|
||||
FROM eclipse-temurin:21 AS build
|
||||
LABEL authors="jessebrault"
|
||||
WORKDIR /jb-ssg-site/
|
||||
COPY . .
|
||||
RUN --mount=type=secret,id=JBARCHIVA_USERNAME,env=JBARCHIVA_USERNAME \
|
||||
--mount=type=secret,id=JBARCHIVA_PASSWORD,env=JBARCHIVA_PASSWORD \
|
||||
./gradlew createSsgBinScript && \
|
||||
bin/ssg build -g && \
|
||||
./gradlew installServerDist
|
||||
|
||||
FROM eclipse-temurin:21
|
||||
LABEL authors="jessebrault"
|
||||
WORKDIR /jb-ssg-site
|
||||
COPY --from=build /jb-ssg-site/dist/ dist/
|
||||
COPY --from=build /jb-ssg-site/static/ static/
|
||||
COPY --from=build /jb-ssg-site/build/install/jb-ssg-site-server/ .
|
||||
EXPOSE 8080
|
||||
CMD ["bin/JbServer"]
|
Loading…
Reference in New Issue
Block a user