Spaces:
Paused
Paused
Commit
•
1e768bf
1
Parent(s):
ff5be78
hmm, testing something
Browse files- Dockerfile +1 -10
- package.json +2 -2
- post-install.sh +0 -13
- src/index.mts +2 -0
- tmp.txt +3 -0
Dockerfile
CHANGED
@@ -19,16 +19,7 @@ RUN apt --yes install build-essential wget curl rpl
|
|
19 |
RUN echo "Build started at: $(date "+%Y-%m-%d %H:%M")"
|
20 |
|
21 |
# NodeJS - LEGACY/DEPRECATED WAY
|
22 |
-
|
23 |
-
#RUN apt --yes install nodejs
|
24 |
-
|
25 |
-
# NodeJS - NEW, MORE ANNOYING WAY
|
26 |
-
RUN apt --yes install -y ca-certificates gnupg
|
27 |
-
RUN mkdir -p /etc/apt/keyrings
|
28 |
-
RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
|
29 |
-
ENV NODE_MAJOR=18
|
30 |
-
RUN echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
|
31 |
-
RUN apt update
|
32 |
RUN apt --yes install nodejs
|
33 |
|
34 |
# git and file management
|
|
|
19 |
RUN echo "Build started at: $(date "+%Y-%m-%d %H:%M")"
|
20 |
|
21 |
# NodeJS - LEGACY/DEPRECATED WAY
|
22 |
+
RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash -
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
RUN apt --yes install nodejs
|
24 |
|
25 |
# git and file management
|
package.json
CHANGED
@@ -6,8 +6,8 @@
|
|
6 |
"scripts": {
|
7 |
"start": "node --loader ts-node/esm src/index.mts",
|
8 |
"docker": "npm run docker:build && npm run docker:run",
|
9 |
-
"docker:build": "docker build -t
|
10 |
-
"docker:run": "docker run -it -p 7860:7860
|
11 |
},
|
12 |
"author": "Julian Bilcke <[email protected]>",
|
13 |
"license": "Apache License",
|
|
|
6 |
"scripts": {
|
7 |
"start": "node --loader ts-node/esm src/index.mts",
|
8 |
"docker": "npm run docker:build && npm run docker:run",
|
9 |
+
"docker:build": "docker build -t splatter-api .",
|
10 |
+
"docker:run": "docker run -it -p 7860:7860 splatter-api"
|
11 |
},
|
12 |
"author": "Julian Bilcke <[email protected]>",
|
13 |
"license": "Apache License",
|
post-install.sh
DELETED
@@ -1,13 +0,0 @@
|
|
1 |
-
#!/bin/bash
|
2 |
-
# This script is used to install the remaining of the app requiring CUDA stuff
|
3 |
-
|
4 |
-
echo "Running post-install script (go take a coffee, this is gonna take a while)"
|
5 |
-
|
6 |
-
echo "cmake -B build"
|
7 |
-
# cmake -B build -D CMAKE_BUILD_TYPE=Release -D CUDA_TOOLKIT_ROOT_DIR=/usr/local/cuda-12.2/ -D CUDA_VERSION=12.2
|
8 |
-
cmake -B build -D CMAKE_BUILD_TYPE=Release -D CUDA_VERSION=12.2
|
9 |
-
|
10 |
-
echo "cmake --build build"
|
11 |
-
cmake --build build -- -j8
|
12 |
-
|
13 |
-
echo "dependency is finally built!"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/index.mts
CHANGED
@@ -1,5 +1,7 @@
|
|
|
|
1 |
|
2 |
import express from "express"
|
|
|
3 |
import { initFolders } from "./initFolders.mts"
|
4 |
|
5 |
initFolders()
|
|
|
1 |
+
console.log("splatter-api is booting up")
|
2 |
|
3 |
import express from "express"
|
4 |
+
|
5 |
import { initFolders } from "./initFolders.mts"
|
6 |
|
7 |
initFolders()
|
tmp.txt
CHANGED
@@ -135,6 +135,9 @@ RUN cmake --build build -- -j8
|
|
135 |
|
136 |
COPY --chown=user . $HOME/app/gaussian-splatting-cuda
|
137 |
|
|
|
|
|
|
|
138 |
RUN echo "Build ended at: $(date "+%Y-%m-%d %H:%M")"
|
139 |
|
140 |
EXPOSE 7860
|
|
|
135 |
|
136 |
COPY --chown=user . $HOME/app/gaussian-splatting-cuda
|
137 |
|
138 |
+
# Set the working directory to the user's home directory
|
139 |
+
WORKDIR $HOME/app
|
140 |
+
|
141 |
RUN echo "Build ended at: $(date "+%Y-%m-%d %H:%M")"
|
142 |
|
143 |
EXPOSE 7860
|