diff --git a/docker-compose.yml b/docker-compose.yml index 91d4c8c..a7bf042 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -559,6 +559,27 @@ x-flowise-base: &flowise-base - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro +x-opencode-base: &opencode-base + image: ghcr.io/anomalyco/opencode:latest + hostname: ${codehostname} + container_name: ${codehostname} + pull_policy: ${pull_policy} + restart: ${restart} + stdin_open: true + tty: true + environment: + - ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY:-} + - OPENAI_API_KEY=${OPENAI_API_KEY:-} + - GEMINI_API_KEY=${GEMINI_API_KEY:-} + - OPENCODE_SERVER_PASSWORD=${OPENCODE_SERVER_PASSWORD} + ports: + - ${OCPORT}:4096 + volumes: + - /etc/timezone:/etc/timezone:ro + - /etc/localtime:/etc/localtime:ro + - ./opencode:/opencode + #entrypoint: ["/bin/sh", "-c", "opencode web --hostname 0.0.0.0"] # uncomment to enable web service + ################################################ services: @@ -774,3 +795,7 @@ services: redis-all: condition: service_healthy restart: true + + opencode-all: + <<: *opencode-base + profiles: ["opencode"] diff --git a/env.example b/env.example index b219e38..bede1ee 100644 --- a/env.example +++ b/env.example @@ -71,7 +71,6 @@ whostname=whisper # crawl4ai CRAWL4AI_API_TOKEN=example #change me -OPENAI_API_KEY=example #change me CLAUDE_API_KEY=example #change me CRAW1=11235 CRAW2=8001 @@ -128,7 +127,15 @@ METRICS_OPEN_TELEMETRY_DEBUG=false DISABLE_FLOWISE_TELEMETRY=true fhostname=flowise +# opencode +codehostname=opencode +OPENCODE_SERVER_PASSWORD=MtsNFjb3541wObuWVYA48DPi21BSjRdA #change me +ANTHROPIC_API_KEY=example #change me +GEMINI_API_KEY=example #change me +OCPORT=4096 + # global restart=always pull_policy=always UOLLAMA='http://ollama:11434' +OPENAI_API_KEY=example #change me diff --git a/Dockerfile b/legacy/Dockerfile similarity index 100% rename from Dockerfile rename to legacy/Dockerfile diff --git a/readme.md b/readme.md index ef7d1e2..82262da 100644 --- a/readme.md +++ b/readme.md @@ -30,6 +30,7 @@ Profiles you can run: * [MongoDB](https://www.mongodb.com) on AMD64 (--profile mongodb) * [EvolutionAPI](https://doc.evolution-api.com/v1/en/get-started/introduction) on AMD64/ARM64 (--profile evolutionapi) * [Flowise](https://github.com/flowiseai/flowise) on AMD64/ARM64 (--profile flowise) +* [Opencode](https://github.com/anomalyco/opencode) on AMD64 (--profile opencode) To run N8N with OpenwebUI: