Luca448 commited on
Commit
7e34fe7
·
1 Parent(s): 2f2c0ea

Savestate: Fix sql-wasm.wasm missing in dist after Docker build

Browse files
Files changed (2) hide show
  1. Dockerfile +4 -1
  2. index.html +1 -1
Dockerfile CHANGED
@@ -50,12 +50,15 @@ RUN npm install
50
  # Copy application source
51
  COPY . .
52
 
53
- # Download missing binary assets that were removed from Git
54
  RUN wget -q -O public/sql-wasm.wasm https://cdnjs.cloudflare.com/ajax/libs/sql.js/1.10.2/sql-wasm.wasm || echo "sql-wasm.wasm download failed"
55
 
56
  # Build Vite App
57
  RUN npm run build
58
 
 
 
 
59
  # Expose Hugging Face Space port
60
  EXPOSE 7860
61
 
 
50
  # Copy application source
51
  COPY . .
52
 
53
+ # Download missing binary assets before build so Vite copies them from public/ to dist/
54
  RUN wget -q -O public/sql-wasm.wasm https://cdnjs.cloudflare.com/ajax/libs/sql.js/1.10.2/sql-wasm.wasm || echo "sql-wasm.wasm download failed"
55
 
56
  # Build Vite App
57
  RUN npm run build
58
 
59
+ # Safety: ensure wasm is in dist even if Vite didn't copy it
60
+ RUN cp -n public/sql-wasm.wasm dist/sql-wasm.wasm 2>/dev/null || true
61
+
62
  # Expose Hugging Face Space port
63
  EXPOSE 7860
64
 
index.html CHANGED
@@ -51,7 +51,7 @@
51
  </head>
52
  <body class="dark-theme in-chat-view">
53
 
54
- <div id="live-version-badge" style="position: fixed; top: 50px; left: 50%; transform: translateX(-50%); font-size: 10px; color: var(--text-secondary); opacity: 0.6; z-index: 99999; pointer-events: none; font-weight: 500; font-family: monospace; letter-spacing: 1px; background: rgba(0,0,0,0.2); padding: 2px 8px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.05);">BUILD 1.1.35</div>
55
 
56
  <!-- SVG Filters for Liquid Glass Refraction -->
57
  <svg width="0" height="0" style="position: absolute; pointer-events: none;">
 
51
  </head>
52
  <body class="dark-theme in-chat-view">
53
 
54
+ <div id="live-version-badge" style="position: fixed; top: 50px; left: 50%; transform: translateX(-50%); font-size: 10px; color: var(--text-secondary); opacity: 0.6; z-index: 99999; pointer-events: none; font-weight: 500; font-family: monospace; letter-spacing: 1px; background: rgba(0,0,0,0.2); padding: 2px 8px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.05);">BUILD 1.1.36</div>
55
 
56
  <!-- SVG Filters for Liquid Glass Refraction -->
57
  <svg width="0" height="0" style="position: absolute; pointer-events: none;">