From afe55e762344f5ed18c63aaeb583d303ab8b0f82 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20Bedna=C5=99=C3=ADk?= <jan.bednarik@gmail.com>
Date: Thu, 1 Feb 2024 16:30:14 +0100
Subject: [PATCH] Nginx serve robots.txt

---
 Dockerfile.nginx | 2 +-
 nginx.conf       | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/Dockerfile.nginx b/Dockerfile.nginx
index d3ed7f54..6483e29d 100644
--- a/Dockerfile.nginx
+++ b/Dockerfile.nginx
@@ -1,3 +1,3 @@
-FROM nginx:1.18
+FROM nginx:latest
 EXPOSE 8080
 ADD nginx.conf /etc/nginx/conf.d/majak.conf
diff --git a/nginx.conf b/nginx.conf
index 8d1a9d66..56a07fe8 100644
--- a/nginx.conf
+++ b/nginx.conf
@@ -18,6 +18,10 @@ server {
         alias /var/opt/majak/media_files/;
     }
 
+    location = /robots.txt {
+        alias /var/opt/majak/robots.txt;
+    }
+
     location / {
         proxy_pass http://majak/;
         proxy_set_header Host $host;
-- 
GitLab