File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change 1
1
# Build stage
2
- FROM ghcr.io/getzola/zola:v0.17.1 as zola
2
+ FROM debian:bullseye-slim as builder
3
+
4
+ # Install necessary tools
5
+ RUN apt-get update && apt-get install -y git wget
6
+
7
+ # Install Zola
8
+ RUN wget https://github.com/getzola/zola/releases/download/v0.17.1/zola-v0.17.1-x86_64-unknown-linux-gnu.tar.gz && \
9
+ tar -xzf zola-v0.17.1-x86_64-unknown-linux-gnu.tar.gz && \
10
+ mv zola /usr/local/bin/zola
3
11
4
12
WORKDIR /project
5
13
COPY . .
6
14
7
- # Ensure Git is available
8
- RUN apt-get update && apt-get install -y git
9
-
10
15
# Initialize and update submodules
11
16
RUN git submodule update --init --recursive
12
17
13
18
# Build the site
14
- RUN [ " zola" , " build" ]
19
+ RUN zola build
15
20
16
21
# Serve stage
17
22
FROM ghcr.io/static-web-server/static-web-server:2
18
23
WORKDIR /
19
- COPY --from=zola /project/public /public
24
+ COPY --from=builder /project/public /public
20
25
21
26
# Optional: Expose a port if necessary, e.g., 80 or 8080
22
27
EXPOSE 80
You can’t perform that action at this time.
0 commit comments