Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ For a local evaluation or development, `docker-compose.yml` starts the whole sta
docker compose up -d
```

Then open <http://localhost:3100/oauth/idp/signup> to create the admin account, and add an LLM under **Settings**. Agent Canvas is served at <http://localhost:3100/canvas/>. Data is kept in named volumes, so it survives `docker compose down`; run `docker compose down -v` to reset everything. If you change `APP_PORT` or access it through another hostname, set `WEB_HOST`, `WEB_URL` and `AGENT_CANVAS_LOCK_TO_CLOUD` to match (see the comments in `docker-compose.yml`).
Then open <http://localhost:9043/oauth/idp/signup> to create the admin account, and add an LLM under **Settings**. Agent Canvas is served at <http://localhost:9043/canvas/>. Data is kept in named volumes, so it survives `docker compose down`; run `docker compose down -v` to reset everything. If you change `APP_PORT` or access it through another hostname, set `WEB_HOST`, `WEB_URL` and `AGENT_CANVAS_LOCK_TO_CLOUD` to match (see the comments in `docker-compose.yml`).

To test your local changes, build `app` and `worker` from your checkout instead of pulling the release image:

Expand Down
2 changes: 1 addition & 1 deletion containers/app/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
ARG AGENT_CANVAS_SOURCE
COPY --from=agent-canvas-source / /agent-canvas-source
# Same-origin URL (scheme + host + port) the browser will use to reach this
# app, e.g. http://localhost:3100. Passed through to
# app, e.g. http://localhost:9043. Passed through to
# scripts/build-agent-canvas.sh as AGENT_CANVAS_LOCK_TO_CLOUD, which bakes it
# into the Canvas bundle as VITE_LOCK_TO_CLOUD -- this is what lets Canvas
# skip its own onboarding and authenticate via this app's existing session
Expand Down Expand Up @@ -102,7 +102,7 @@

# Datadog labels
LABEL com.datadoghq.tags.service="deploy"
LABEL com.datadoghq.tags.env="${DD_ENV}"

Check warning on line 105 in containers/app/Dockerfile

View workflow job for this annotation

GitHub Actions / Enterprise / Build ghcr.io/openhands/enterprise-server (arm64)

Variables should be defined before their use

UndefinedVar: Usage of undefined variable '$DD_ENV' More info: https://docs.docker.com/go/dockerfile/rule/undefined-var/

Check warning on line 105 in containers/app/Dockerfile

View workflow job for this annotation

GitHub Actions / Enterprise / Build ghcr.io/openhands/enterprise-server (amd64)

Variables should be defined before their use

UndefinedVar: Usage of undefined variable '$DD_ENV' More info: https://docs.docker.com/go/dockerfile/rule/undefined-var/

ENV RUN_AS_OPENHANDS=true
# A random number--we need this to be different from the user's UID on the host machine
Expand Down
20 changes: 10 additions & 10 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@ services:
DB_PASS: ${DB_PASS:-openhands}
OH_DEPLOYMENT_MODE: self_hosted
OH_APP_MODE: saas
PERMITTED_CORS_ORIGINS: http://localhost:${APP_PORT:-3100}
PERMITTED_CORS_ORIGINS: http://localhost:${APP_PORT:-9043}
# If you open the app on an address other than localhost, set WEB_HOST and WEB_URL to that address.
WEB_HOST: ${WEB_HOST:-localhost}
OH_WEB_URL: ${WEB_URL:-http://localhost:${APP_PORT:-3100}}
OH_WEB_URL: ${WEB_URL:-http://localhost:${APP_PORT:-9043}}
# Sandboxes reach the app through the proxy.
OH_SANDBOX_WEB_URL: http://proxy
RUN_MIGRATIONS_ON_STARTUP: 'true'
Expand All @@ -59,9 +59,9 @@ services:
# Rate limiting needs Redis, which this stack does not include.
RATE_LIMITING_ENABLED: 'false'
POSTHOG_CLIENT_KEY: ${POSTHOG_CLIENT_KEY:-}
SANDBOX_HOST_PORT: ${APP_PORT:-3100}
SANDBOX_HOST_PORT: ${APP_PORT:-9043}
SANDBOX_DOCKER_NETWORK: ${COMPOSE_PROJECT_NAME}_default
SANDBOX_CONTAINER_URL_PATTERN: ${WEB_URL:-http://localhost:${APP_PORT:-3100}}/runtime/{sandbox_id}/{port}
SANDBOX_CONTAINER_URL_PATTERN: ${WEB_URL:-http://localhost:${APP_PORT:-9043}}/runtime/{sandbox_id}/{port}
# New conversations reuse the running sandbox with the fewest conversations, so fewer sandbox containers run.
OH_APP_CONVERSATION_SANDBOX_GROUPING_STRATEGY: FEWEST_CONVERSATIONS
OH_AGENT_SERVER_ENV: '{"AGENT_SERVER_PORT": "8000"}'
Expand Down Expand Up @@ -90,7 +90,7 @@ services:
- '8000'
volumes:
- automation-data:/data
# Sandbox URLs use localhost:3100, so localhost must point to the Docker host, where the proxy listens.
# Sandbox URLs use localhost:9043, so localhost must point to the Docker host, where the proxy listens.
extra_hosts:
- 'host.docker.internal:host-gateway'
- 'localhost:host-gateway'
Expand All @@ -112,7 +112,7 @@ services:
AUTOMATION_KV_SECRET: ${AUTOMATION_KV_SECRET:-local-compose-kv-secret}
# Sandboxes call the automation service at this URL.
AUTOMATION_BASE_URL: http://proxy
AUTOMATION_CORS_ORIGINS: http://localhost:${APP_PORT:-3100}
AUTOMATION_CORS_ORIGINS: http://localhost:${APP_PORT:-9043}
healthcheck:
test: ['CMD', 'python', '-c', "import urllib.request; urllib.request.urlopen('http://localhost:8000/ready')"]
interval: 5s
Expand All @@ -125,7 +125,7 @@ services:
init: true
# The image includes other servers, but this stack only needs its static file server.
entrypoint: ['node', '/opt/agent-canvas/static-server.mjs']
# AGENT_CANVAS_LOCK_TO_CLOUD must exactly match the address in your browser, such as http://localhost:3100.
# AGENT_CANVAS_LOCK_TO_CLOUD must exactly match the address in your browser, such as http://localhost:9043.
command:
- --port
- '8000'
Expand All @@ -136,7 +136,7 @@ services:
- --base-path
- /canvas
- --lock-to-cloud
- ${AGENT_CANVAS_LOCK_TO_CLOUD:-http://localhost:${APP_PORT:-3100}}
- ${AGENT_CANVAS_LOCK_TO_CLOUD:-http://localhost:${APP_PORT:-9043}}
- --disable-telemetry
expose:
- '8000'
Expand All @@ -147,7 +147,7 @@ services:
retries: 20
restart: unless-stopped

# Caddy is used as a reverse proxy, and all traffic is served via localhost:3100.
# Caddy is used as a reverse proxy, and all traffic is served via localhost:9043.
proxy:
image: caddy:2
depends_on:
Expand All @@ -158,7 +158,7 @@ services:
canvas-server:
condition: service_healthy
ports:
- '${APP_PORT:-3100}:80'
- '${APP_PORT:-9043}:80'
configs:
- source: caddyfile
target: /etc/caddy/Caddyfile
Expand Down
Loading