site/Dockerfile

25 lines
472 B
Docker
Raw Normal View History

2022-03-29 16:01:16 +02:00
FROM alpine:3.15.3 AS builder
RUN apk update && \
apk add --no-cache \
hugo
WORKDIR /app
COPY . ./
# Build the site
RUN hugo
FROM nginx:1.21.6-alpine
2022-03-29 16:34:00 +02:00
ENV MATRIX_SERVER=matrix.rustybever.be:443 \
MATRIX_CLIENT_SERVER=https://matrix.rustybever.be
2022-03-29 16:01:16 +02:00
COPY nginx/nginx.conf /etc/nginx/nginx.conf
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
COPY nginx/*.conf.template /etc/nginx/templates/
COPY --from=builder /app/public /usr/share/nginx/html