Add Dockerfile, docker-compose.yml, .dockerignore
This commit is contained in:
parent
481915587e
commit
2261cbf1a0
3 changed files with 80 additions and 0 deletions
10
.dockerignore
Normal file
10
.dockerignore
Normal file
|
|
@ -0,0 +1,10 @@
|
||||||
|
venv/
|
||||||
|
.venv/
|
||||||
|
__pycache__/
|
||||||
|
*.pyc
|
||||||
|
.git/
|
||||||
|
node_modules/
|
||||||
|
.env
|
||||||
|
config.yaml
|
||||||
|
sessions/
|
||||||
|
logs/
|
||||||
17
Dockerfile
Normal file
17
Dockerfile
Normal file
|
|
@ -0,0 +1,17 @@
|
||||||
|
FROM nikolaik/python-nodejs:python3.11-nodejs20
|
||||||
|
|
||||||
|
RUN apt-get update && apt-get install -y \
|
||||||
|
curl \
|
||||||
|
git \
|
||||||
|
docker.io \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
COPY pyproject.toml requirements.txt* ./
|
||||||
|
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
RUN pip install -e .
|
||||||
|
|
||||||
|
CMD ["python", "-m", "gateway.run"]
|
||||||
53
docker-compose.yml
Normal file
53
docker-compose.yml
Normal file
|
|
@ -0,0 +1,53 @@
|
||||||
|
version: '3.8'
|
||||||
|
|
||||||
|
services:
|
||||||
|
browser:
|
||||||
|
image: browserless/chrome:latest
|
||||||
|
ports:
|
||||||
|
- "3000:3000"
|
||||||
|
environment:
|
||||||
|
- MAX_CONCURRENT_SESSIONS=5
|
||||||
|
- ENABLE_DEBUGGER=true
|
||||||
|
restart: always
|
||||||
|
networks:
|
||||||
|
- hermes-net
|
||||||
|
deploy:
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
memory: 2G
|
||||||
|
|
||||||
|
agent:
|
||||||
|
build: .
|
||||||
|
container_name: hermes-brain
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
volumes:
|
||||||
|
- .:/app:ro
|
||||||
|
- ~/.hermes/config.yaml:/app/config.yaml:ro
|
||||||
|
- ~/.hermes/SOUL.md:/app/SOUL.md:ro
|
||||||
|
- ~/.hermes/sessions:/app/sessions:rw
|
||||||
|
- ~/.hermes/logs:/app/logs:rw
|
||||||
|
- ~/.hermes/workspaces:/app/workspaces:rw
|
||||||
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
environment:
|
||||||
|
- BROWSER_URL=ws://browser:3000
|
||||||
|
depend_on:
|
||||||
|
- browser
|
||||||
|
stdin_open: true
|
||||||
|
tty: true
|
||||||
|
restart: always
|
||||||
|
networks:
|
||||||
|
- hermes-net
|
||||||
|
|
||||||
|
networks:
|
||||||
|
hermes-net:
|
||||||
|
driver: bridge
|
||||||
|
|
||||||
|
|
||||||
|
# Optional: SSL configuration if needed
|
||||||
|
# extra_hosts:
|
||||||
|
# - "host.docker.internal:host-gateway"
|
||||||
|
|
||||||
|
# Uncomment the following if you need persistent logging or data
|
||||||
|
# volumes:
|
||||||
|
# - ./logs:/tmp/logs
|
||||||
Loading…
Add table
Add a link
Reference in a new issue