From 94f83f9a859b04d7a494cff5652a0a7abe7a218e Mon Sep 17 00:00:00 2001
From: Eugen Ciur <eugen@papermerge.com>
Date: Wed, 29 Dec 2021 07:14:07 +0100
Subject: [PATCH] fix minor issue with nginx dockerization

---
 docker/Dockerfile |  3 +++
 docker/nginx.conf | 13 +++++++++++++
 2 files changed, 16 insertions(+)
 create mode 100644 docker/nginx.conf

diff --git a/docker/Dockerfile b/docker/Dockerfile
index 8d46ebc..628c435 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -18,3 +18,6 @@ RUN ember build --environment production
 FROM nginx:1.21.1-alpine
 
 COPY --from=build /src/dist/ /usr/share/nginx/html
+COPY docker/nginx.conf /etc/nginx/conf.d/default.conf
+
+ENTRYPOINT ["nginx", "-g", "daemon off;"]
diff --git a/docker/nginx.conf b/docker/nginx.conf
new file mode 100644
index 0000000..df62576
--- /dev/null
+++ b/docker/nginx.conf
@@ -0,0 +1,13 @@
+server {
+    root /usr/share/nginx/html;
+    index index.html index.htm;
+    listen 80;
+
+    location / {
+        try_files $uri $uri/ /index.html =404;
+    }
+
+    location /assets {
+        try_files $uri $uri/ =404;
+    }
+}
\ No newline at end of file
-- 
GitLab