build & deploy with docker

This commit is contained in:
2024-12-14 16:34:28 +01:00
parent 16ddc45a17
commit 449b567057
51 changed files with 56 additions and 2 deletions

BIN
.DS_Store vendored Normal file

Binary file not shown.

13
Dockerfile Normal file
View File

@@ -0,0 +1,13 @@
# Compile the hugo site
FROM ubuntu:latest AS builder
RUN apt-get update && apt-get install -y hugo
COPY ./hugo /app
RUN hugo -s /app
# Setup deployment
FROM nginx:alpine AS final
COPY ./nginx/nginx.conf /etc/nginx/nginx.conf
COPY --from=0 /var/www/rezepte /var/www

BIN
hugo/.DS_Store vendored Normal file

Binary file not shown.

BIN
hugo/assets/.DS_Store vendored Normal file

Binary file not shown.

BIN
hugo/layouts/.DS_Store vendored Normal file

Binary file not shown.

BIN
hugo/static/.DS_Store vendored Normal file

Binary file not shown.

View File

Before

Width:  |  Height:  |  Size: 52 KiB

After

Width:  |  Height:  |  Size: 52 KiB

View File

Before

Width:  |  Height:  |  Size: 61 KiB

After

Width:  |  Height:  |  Size: 61 KiB

View File

Before

Width:  |  Height:  |  Size: 70 KiB

After

Width:  |  Height:  |  Size: 70 KiB

View File

Before

Width:  |  Height:  |  Size: 246 KiB

After

Width:  |  Height:  |  Size: 246 KiB

BIN
hugo/themes/.DS_Store vendored Normal file

Binary file not shown.

43
nginx/nginx.conf Normal file
View File

@@ -0,0 +1,43 @@
# nginx.conf
worker_processes auto;
events {
worker_connections 1024;
}
http {
# Logging
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
# Gzip compression
gzip on;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
gzip_min_length 256;
server {
listen 80;
server_name example.com;
root /var/www/;
index index.html;
# Error pages
#error_page 404 /404.html;
#location = /404.html {
# internal;
#}
# Serve static files
location / {
try_files $uri $uri/ =404;
}
# Optional: Caching for static assets
location ~* \.(?:ico|css|js|gif|jpe?g|png|svg|woff2?|ttf|otf|eot|html|xml|json)$ {
expires 10M;
access_log off;
add_header Cache-Control "public";
}
}
}

Submodule themes/archie deleted from d8819d5eee

Submodule themes/lugo deleted from 62ac46a295