From 65007297a0aa2d893e2e81315faf52e543341aa3 Mon Sep 17 00:00:00 2001 From: mstfyldz Date: Fri, 6 Mar 2026 19:34:38 +0300 Subject: [PATCH] docker --- dockerfile | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 dockerfile diff --git a/dockerfile b/dockerfile new file mode 100644 index 0000000..7d5214a --- /dev/null +++ b/dockerfile @@ -0,0 +1,20 @@ +# En hafif Nginx imajını kullanıyoruz +FROM nginx:alpine + +# JSON dosyasını Nginx'in varsayılan yayın klasörüne kopyala +COPY config.json /usr/share/nginx/html/config.json + +# (Opsiyonel) CORS hatalarını önlemek için özel bir Nginx konfigürasyonu ekleyelim +RUN echo 'server { \ + listen 80; \ + location / { \ + root /usr/share/nginx/html; \ + index index.json; \ + add_header Access-Control-Allow-Origin *; \ + add_header Content-Type application/json; \ + } \ +}' > /etc/nginx/conf.d/default.conf + +EXPOSE 80 + +CMD ["nginx", "-g", "daemon off;"] \ No newline at end of file