awooda commited on
Commit
45da12f
·
verified ·
1 Parent(s): 2cec79b

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +10 -10
Dockerfile CHANGED
@@ -1,23 +1,23 @@
1
  FROM node:22-bookworm
2
 
3
- # Install basic dependencies
4
- RUN apt-get update && apt-get install -y curl git procps && rm -rf /var/lib/apt/lists/*
 
 
5
 
6
- # Install Ollama using the official script (handles architecture automatically)
7
- RUN curl -fsSL https://ollama.com/install.sh | sh
 
8
 
9
- # Install OpenClaw
10
  RUN npm install -g openclaw@latest --unsafe-perm=true
11
 
12
- # Set environment variables for OpenClaw
13
- ENV OPENCLAW_GATEWAY_PORT=7860
14
- ENV OPENCLAW_GATEWAY_HOST=0.0.0.0
15
-
16
  WORKDIR /app
17
  COPY start.sh /start.sh
18
  RUN chmod +x /start.sh
19
 
20
- # HF uses 7860
21
  EXPOSE 7860
22
 
23
  CMD ["/start.sh"]
 
1
  FROM node:22-bookworm
2
 
3
+ # 1. Install EVERYTHING needed for building native modules
4
+ RUN apt-get update && apt-get install -y \
5
+ curl git procps build-essential python3 make g++ \
6
+ && rm -rf /var/lib/apt/lists/*
7
 
8
+ # 2. Install Ollama using the official binary method
9
+ RUN curl -L https://ollama.com/download/ollama-linux-amd64 -o /usr/bin/ollama \
10
+ && chmod +x /usr/bin/ollama
11
 
12
+ # 3. Install OpenClaw with the "Unsafe Perm" flag for HF
13
  RUN npm install -g openclaw@latest --unsafe-perm=true
14
 
15
+ # 4. Final setup
 
 
 
16
  WORKDIR /app
17
  COPY start.sh /start.sh
18
  RUN chmod +x /start.sh
19
 
20
+ # HF standard port
21
  EXPOSE 7860
22
 
23
  CMD ["/start.sh"]