From 3a2a39733431c17fbad12f4164ecd9e1738c21fc Mon Sep 17 00:00:00 2001 From: Senthilkumar Panneerselvam Date: Tue, 10 Sep 2024 09:09:29 +0200 Subject: [PATCH] Prevent from being used in iframe --- Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Dockerfile b/Dockerfile index a8fa2fc..eef3032 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,6 +15,7 @@ RUN mkdir /target && \ # Serve the generated html using nginx FROM nginxinc/nginx-unprivileged:alpine RUN sed -i '3 a\ absolute_redirect off;' /etc/nginx/conf.d/default.conf && \ + sed -i '4 a\ add_header X-Frame-Options DENY always;' /etc/nginx/conf.d/default.conf && \ sed -i 's/#error_page 404/error_page 404/' /etc/nginx/conf.d/default.conf COPY --from=build /target /usr/share/nginx/html