jurmy24 commited on
Commit
74a884c
·
1 Parent(s): 8f8a205

fix: get nginx to expose port 7860

Browse files
Files changed (3) hide show
  1. Dockerfile +10 -3
  2. README.md +1 -0
  3. viewer/package.json +1 -0
Dockerfile CHANGED
@@ -18,11 +18,18 @@ FROM nginx:alpine
18
  # Copy built assets from build stage
19
  COPY --from=build /app/dist /usr/share/nginx/html
20
 
21
- # Copy nginx configuration if needed
22
- # COPY nginx.conf /etc/nginx/conf.d/default.conf
 
 
 
 
 
 
 
23
 
24
  # Expose port
25
- EXPOSE 80
26
 
27
  # Start nginx
28
  CMD ["nginx", "-g", "daemon off;"]
 
18
  # Copy built assets from build stage
19
  COPY --from=build /app/dist /usr/share/nginx/html
20
 
21
+ # Configure nginx to use port 7860 and support SPA routing
22
+ RUN echo 'server { \
23
+ listen 7860; \
24
+ root /usr/share/nginx/html; \
25
+ index index.html; \
26
+ location / { \
27
+ try_files $uri $uri/ /index.html; \
28
+ } \
29
+ }' > /etc/nginx/conf.d/default.conf
30
 
31
  # Expose port
32
+ EXPOSE 7860
33
 
34
  # Start nginx
35
  CMD ["nginx", "-g", "daemon off;"]
README.md CHANGED
@@ -4,6 +4,7 @@ emoji: ⚡
4
  colorFrom: red
5
  colorTo: indigo
6
  sdk: docker
 
7
  pinned: false
8
  short_description: Upload a URDF folder to view and interact with your robot.
9
  ---
 
4
  colorFrom: red
5
  colorTo: indigo
6
  sdk: docker
7
+ app_port: 7860
8
  pinned: false
9
  short_description: Upload a URDF folder to view and interact with your robot.
10
  ---
viewer/package.json CHANGED
@@ -45,6 +45,7 @@
45
  "@tanstack/react-query-devtools": "^5.71.1",
46
  "@types/three": "^0.174.0",
47
  "@types/uuid": "^10.0.0",
 
48
  "class-variance-authority": "^0.7.1",
49
  "clsx": "^2.1.1",
50
  "cmdk": "^1.0.0",
 
45
  "@tanstack/react-query-devtools": "^5.71.1",
46
  "@types/three": "^0.174.0",
47
  "@types/uuid": "^10.0.0",
48
+ "caniuse-lite": "^1.0.30001715",
49
  "class-variance-authority": "^0.7.1",
50
  "clsx": "^2.1.1",
51
  "cmdk": "^1.0.0",