Skip to content

Commit 13bed87

Browse files
committed
Fix nginx deployment
1 parent 70832f9 commit 13bed87

File tree

3 files changed

+17
-1
lines changed

3 files changed

+17
-1
lines changed

frontend/Dockerfile.prod

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ RUN npm run build
1010

1111
# Serve stage
1212
FROM nginx:alpine
13+
COPY nginx.conf /etc/nginx/conf.d/default.conf
1314
COPY --from=build /app/build /usr/share/nginx/html
1415
EXPOSE 80
1516
CMD ["nginx", "-g", "daemon off;"]

frontend/nginx.conf

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
server {
2+
listen 80;
3+
server_name localhost;
4+
5+
location / {
6+
root /usr/share/nginx/html;
7+
index index.html index.htm;
8+
try_files $uri /index.html;
9+
}
10+
11+
error_page 500 502 503 504 /50x.html;
12+
location = /50x.html {
13+
root /usr/share/nginx/html;
14+
}
15+
}

frontend/src/reducers/authSlice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const dummyAdmin: User = {
3030
};
3131

3232
const initialState: AuthState = {
33-
user: dummyUser // null
33+
user: null
3434
}
3535

3636
const userSlice = createSlice({

0 commit comments

Comments
 (0)