Maybe this finally works...
This commit is contained in:
parent
0885320deb
commit
94d181cd3d
1 changed files with 6 additions and 5 deletions
11
Dockerfile
11
Dockerfile
|
@ -1,13 +1,14 @@
|
||||||
# Build stage
|
# Build stage
|
||||||
FROM golang:1.21-alpine AS builder
|
FROM golang:1.24-alpine AS builder
|
||||||
|
|
||||||
# Install Hugo, Git, and SSL certificates
|
WORKDIR /app
|
||||||
RUN apk add --no-cache hugo git ca-certificates
|
|
||||||
|
# Install Hugo and Git
|
||||||
|
RUN apk add --no-cache hugo git
|
||||||
|
|
||||||
# Copy the repository contents
|
# Copy the repository contents
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
|
|
||||||
# Build the site
|
# Build the site
|
||||||
RUN hugo --minify
|
RUN hugo --minify
|
||||||
|
|
||||||
|
@ -15,7 +16,7 @@ RUN hugo --minify
|
||||||
FROM nginx:alpine
|
FROM nginx:alpine
|
||||||
|
|
||||||
# Copy the built site from builder
|
# Copy the built site from builder
|
||||||
COPY --from=builder /public /usr/share/nginx/html
|
COPY --from=builder /app/public /usr/share/nginx/html
|
||||||
|
|
||||||
# Copy custom nginx config if needed
|
# Copy custom nginx config if needed
|
||||||
# COPY nginx.conf /etc/nginx/conf.d/default.conf
|
# COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||||
|
|
Loading…
Add table
Reference in a new issue