28 lines
518 B
Docker
28 lines
518 B
Docker
FROM node:22-alpine
|
|
|
|
# Install dependencies
|
|
RUN apk add --no-cache \
|
|
python3 \
|
|
make \
|
|
g++ \
|
|
curl \
|
|
git \
|
|
bash
|
|
|
|
# Install OpenClaw from npm
|
|
RUN npm install -g openclaw-cli
|
|
|
|
# Create config directory
|
|
RUN mkdir -p /root/.openclaw
|
|
|
|
# Expose ports
|
|
EXPOSE 3000 3001
|
|
|
|
# Health check
|
|
HEALTHCHECK --interval=30s --timeout=10s --start-period=40s --retries=3 \
|
|
CMD curl -f http://localhost:3000/health 2>/dev/null || exit 1
|
|
|
|
# Start OpenClaw with CLI command
|
|
ENTRYPOINT ["openclaw-cli"]
|
|
CMD ["start"]
|