container-superposition 0.1.7 → 0.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (122) hide show
  1. package/README.md +24 -15
  2. package/dist/scripts/init.js +1 -1537
  3. package/dist/scripts/init.js.map +1 -1
  4. package/dist/tool/cli/args.d.ts +20 -0
  5. package/dist/tool/cli/args.d.ts.map +1 -0
  6. package/dist/tool/cli/args.js +325 -0
  7. package/dist/tool/cli/args.js.map +1 -0
  8. package/dist/tool/cli/run.d.ts +2 -0
  9. package/dist/tool/cli/run.d.ts.map +1 -0
  10. package/dist/tool/cli/run.js +318 -0
  11. package/dist/tool/cli/run.js.map +1 -0
  12. package/dist/tool/commands/doctor.d.ts.map +1 -1
  13. package/dist/tool/commands/doctor.js +141 -6
  14. package/dist/tool/commands/doctor.js.map +1 -1
  15. package/dist/tool/commands/explain.d.ts.map +1 -1
  16. package/dist/tool/commands/explain.js +9 -0
  17. package/dist/tool/commands/explain.js.map +1 -1
  18. package/dist/tool/commands/migrate.d.ts +7 -0
  19. package/dist/tool/commands/migrate.d.ts.map +1 -0
  20. package/dist/tool/commands/migrate.js +52 -0
  21. package/dist/tool/commands/migrate.js.map +1 -0
  22. package/dist/tool/questionnaire/answers.d.ts +16 -0
  23. package/dist/tool/questionnaire/answers.d.ts.map +1 -0
  24. package/dist/tool/questionnaire/answers.js +102 -0
  25. package/dist/tool/questionnaire/answers.js.map +1 -0
  26. package/dist/tool/questionnaire/composer.d.ts +3 -3
  27. package/dist/tool/questionnaire/composer.d.ts.map +1 -1
  28. package/dist/tool/questionnaire/composer.js +691 -27
  29. package/dist/tool/questionnaire/composer.js.map +1 -1
  30. package/dist/tool/questionnaire/presets.d.ts +60 -0
  31. package/dist/tool/questionnaire/presets.d.ts.map +1 -0
  32. package/dist/tool/questionnaire/presets.js +164 -0
  33. package/dist/tool/questionnaire/presets.js.map +1 -0
  34. package/dist/tool/questionnaire/questionnaire.d.ts +10 -0
  35. package/dist/tool/questionnaire/questionnaire.d.ts.map +1 -0
  36. package/dist/tool/questionnaire/questionnaire.js +580 -0
  37. package/dist/tool/questionnaire/questionnaire.js.map +1 -0
  38. package/dist/tool/schema/manifest-migrations.d.ts +5 -0
  39. package/dist/tool/schema/manifest-migrations.d.ts.map +1 -1
  40. package/dist/tool/schema/manifest-migrations.js +45 -0
  41. package/dist/tool/schema/manifest-migrations.js.map +1 -1
  42. package/dist/tool/schema/overlay-loader.d.ts.map +1 -1
  43. package/dist/tool/schema/overlay-loader.js +24 -0
  44. package/dist/tool/schema/overlay-loader.js.map +1 -1
  45. package/dist/tool/schema/project-config.d.ts +13 -1
  46. package/dist/tool/schema/project-config.d.ts.map +1 -1
  47. package/dist/tool/schema/project-config.js +183 -9
  48. package/dist/tool/schema/project-config.js.map +1 -1
  49. package/dist/tool/schema/target-rules.d.ts +78 -0
  50. package/dist/tool/schema/target-rules.d.ts.map +1 -0
  51. package/dist/tool/schema/target-rules.js +367 -0
  52. package/dist/tool/schema/target-rules.js.map +1 -0
  53. package/dist/tool/schema/types.d.ts +38 -1
  54. package/dist/tool/schema/types.d.ts.map +1 -1
  55. package/dist/tool/utils/parameters.d.ts +76 -0
  56. package/dist/tool/utils/parameters.d.ts.map +1 -0
  57. package/dist/tool/utils/parameters.js +125 -0
  58. package/dist/tool/utils/parameters.js.map +1 -0
  59. package/dist/tool/utils/paths.d.ts +2 -0
  60. package/dist/tool/utils/paths.d.ts.map +1 -0
  61. package/dist/tool/utils/paths.js +31 -0
  62. package/dist/tool/utils/paths.js.map +1 -0
  63. package/docs/deployment-targets.md +88 -56
  64. package/docs/examples.md +20 -17
  65. package/docs/filesystem-contract.md +5 -0
  66. package/docs/minimal-and-editor.md +65 -5
  67. package/docs/overlay-imports.md +92 -14
  68. package/docs/overlays.md +113 -28
  69. package/docs/specs/007-init-project-file/spec.md +66 -0
  70. package/docs/specs/007-target-aware-generation/spec.md +126 -0
  71. package/docs/specs/008-project-file-canonical/spec.md +83 -0
  72. package/docs/specs/009-project-env/spec.md +147 -0
  73. package/docs/specs/010-compose-env-materialization/spec.md +130 -0
  74. package/docs/specs/011-overlay-parameters/spec.md +235 -0
  75. package/overlays/.shared/README.md +27 -2
  76. package/overlays/.shared/compose/nvidia-gpu-devcontainer.yml +22 -0
  77. package/overlays/comfyui/.env.example +34 -0
  78. package/overlays/comfyui/README.md +342 -0
  79. package/overlays/comfyui/devcontainer.patch.json +15 -0
  80. package/overlays/comfyui/docker-compose.yml +39 -0
  81. package/overlays/comfyui/overlay.yml +20 -0
  82. package/overlays/comfyui/setup.sh +36 -0
  83. package/overlays/comfyui/verify.sh +103 -0
  84. package/overlays/k3d/README.md +201 -0
  85. package/overlays/k3d/devcontainer.patch.json +9 -0
  86. package/overlays/k3d/overlay.yml +19 -0
  87. package/overlays/k3d/setup.sh +34 -0
  88. package/overlays/k3d/verify.sh +38 -0
  89. package/overlays/ollama/.env.example +14 -0
  90. package/overlays/ollama/README.md +325 -0
  91. package/overlays/ollama/devcontainer.patch.json +14 -0
  92. package/overlays/ollama/docker-compose.yml +24 -0
  93. package/overlays/ollama/overlay.yml +22 -0
  94. package/overlays/ollama/setup.sh +106 -0
  95. package/overlays/ollama/verify.sh +99 -0
  96. package/overlays/open-webui/.env.example +5 -0
  97. package/overlays/open-webui/README.md +162 -0
  98. package/overlays/open-webui/devcontainer.patch.json +14 -0
  99. package/overlays/open-webui/docker-compose.yml +23 -0
  100. package/overlays/open-webui/overlay.yml +38 -0
  101. package/overlays/pgvector/.env.example +6 -0
  102. package/overlays/pgvector/README.md +215 -0
  103. package/overlays/pgvector/devcontainer.patch.json +23 -0
  104. package/overlays/pgvector/docker-compose.yml +32 -0
  105. package/overlays/pgvector/overlay.yml +44 -0
  106. package/overlays/postgres/.env.example +5 -5
  107. package/overlays/postgres/devcontainer.patch.json +4 -4
  108. package/overlays/postgres/docker-compose.yml +10 -6
  109. package/overlays/postgres/overlay.yml +19 -1
  110. package/overlays/qdrant/.env.example +4 -0
  111. package/overlays/qdrant/README.md +216 -0
  112. package/overlays/qdrant/devcontainer.patch.json +20 -0
  113. package/overlays/qdrant/docker-compose.yml +25 -0
  114. package/overlays/qdrant/overlay.yml +40 -0
  115. package/overlays/skaffold/README.md +256 -0
  116. package/overlays/skaffold/devcontainer.patch.json +9 -0
  117. package/overlays/skaffold/overlay.yml +20 -0
  118. package/overlays/skaffold/setup.sh +33 -0
  119. package/overlays/skaffold/verify.sh +24 -0
  120. package/package.json +3 -2
  121. package/tool/schema/config.schema.json +31 -1
  122. package/tool/schema/overlay-manifest.schema.json +33 -0
@@ -0,0 +1,22 @@
1
+ id: ollama
2
+ name: Ollama
3
+ description: Local LLM inference server with OpenAI-compatible API
4
+ category: dev
5
+ supports:
6
+ - compose
7
+ requires: []
8
+ suggests:
9
+ - codex
10
+ - claude-code
11
+ - amp
12
+ conflicts: []
13
+ tags:
14
+ - dev
15
+ - ai
16
+ - llm
17
+ - inference
18
+ - ollama
19
+ ports:
20
+ - 11434
21
+ compose_imports:
22
+ - .shared/compose/nvidia-gpu-devcontainer.yml
@@ -0,0 +1,106 @@
1
+ #!/bin/bash
2
+ # Ollama CLI setup script
3
+ # Installs the Ollama CLI in the devcontainer so developers can manage models
4
+ # and run inference from the terminal, targeting the ollama sidecar service.
5
+
6
+ set -e
7
+
8
+ source "$(dirname "${BASH_SOURCE[0]}")/setup-utils.sh"
9
+
10
+ detect_arch
11
+
12
+ if command_exists ollama; then
13
+ echo "✓ Ollama CLI already installed: $(ollama --version)"
14
+ echo "ℹ️ OLLAMA_HOST is set to ${OLLAMA_HOST:-http://ollama:11434} — all commands target the sidecar."
15
+ exit 0
16
+ fi
17
+
18
+ echo "📦 Installing Ollama CLI..."
19
+ # Prefer copying the CLI binary from the already-present Ollama sidecar image.
20
+ # Compose-based templates include docker-outside-of-docker, so this avoids
21
+ # re-downloading the multi-GB upstream Linux release archive in normal use.
22
+ OLLAMA_IMAGE="ollama/ollama:${OLLAMA_VERSION:-latest}"
23
+ if command_exists docker && docker info >/dev/null 2>&1; then
24
+ tmpdir=$(mktemp -d)
25
+ docker_container_id=""
26
+ trap '[ -n "${docker_container_id}" ] && docker rm -f "${docker_container_id}" >/dev/null 2>&1 || true; rm -rf "${tmpdir}"' EXIT
27
+
28
+ # Guard Docker command substitutions with || fallback so failures here are
29
+ # non-fatal and the archive fallback below can still run.
30
+ container_id="$(docker ps -q --filter "ancestor=${OLLAMA_IMAGE}" 2>/dev/null | head -n 1)" || container_id=""
31
+
32
+ if [ -z "${container_id}" ] && docker image inspect "${OLLAMA_IMAGE}" >/dev/null 2>&1; then
33
+ container_id="$(docker create "${OLLAMA_IMAGE}" 2>/dev/null)" || container_id=""
34
+ [ -n "${container_id}" ] && docker_container_id="${container_id}"
35
+ fi
36
+
37
+ if [ -n "${container_id}" ] && docker cp "${container_id}:/usr/bin/ollama" "${tmpdir}/ollama" >/dev/null 2>&1; then
38
+ echo "📦 Installing Ollama CLI from local Docker image..."
39
+ sudo install -m 0755 "${tmpdir}/ollama" /usr/local/bin/ollama
40
+ fi
41
+
42
+ [ -n "${docker_container_id}" ] && docker rm -f "${docker_container_id}" >/dev/null 2>&1 || true
43
+ docker_container_id=""
44
+ rm -rf "${tmpdir}"
45
+ trap - EXIT
46
+ fi
47
+
48
+ if ! command_exists ollama; then
49
+ # Fallback to official release archives without invoking the full
50
+ # install.sh flow, which configures a local daemon/service that the
51
+ # devcontainer does not need because the sidecar already provides the API.
52
+ OLLAMA_DOWNLOAD_BASE="https://ollama.com/download/ollama-linux-${CS_ARCH}"
53
+
54
+ if curl -fsSLI "${OLLAMA_DOWNLOAD_BASE}.tar.zst" >/dev/null 2>&1; then
55
+ if ! command_exists zstd; then
56
+ echo "📦 Installing zstd for Ollama archive extraction..."
57
+ apt_install zstd
58
+ fi
59
+
60
+ archive_size_bytes="$(
61
+ curl -fsSLI "${OLLAMA_DOWNLOAD_BASE}.tar.zst" |
62
+ awk 'BEGIN { IGNORECASE = 1 } /^content-length:/ { print $2 }' |
63
+ tr -d '\r' |
64
+ tail -n 1
65
+ )"
66
+
67
+ if [ -n "${archive_size_bytes}" ]; then
68
+ archive_size_gib="$(awk "BEGIN { printf \"%.1f\", ${archive_size_bytes} / 1024 / 1024 / 1024 }")"
69
+ echo "⬇️ Downloading official Ollama archive (~${archive_size_gib} GiB)..."
70
+ else
71
+ echo "⬇️ Downloading official Ollama archive..."
72
+ fi
73
+
74
+ tmpdir=$(mktemp -d)
75
+ trap 'rm -rf "${tmpdir}"' EXIT
76
+
77
+ curl --fail --location --progress-bar "${OLLAMA_DOWNLOAD_BASE}.tar.zst" -o "${tmpdir}/ollama.tar.zst"
78
+
79
+ # Match the official Linux package layout so the CLI keeps working even
80
+ # when upstream ships supporting files under lib/ollama alongside the
81
+ # top-level ollama binary.
82
+ echo "📦 Extracting Ollama CLI from archive..."
83
+ sudo rm -rf /usr/local/lib/ollama
84
+ zstd -d -c "${tmpdir}/ollama.tar.zst" | sudo tar -xf - -C /usr/local
85
+ sudo install -d /usr/local/bin
86
+ sudo ln -sf /usr/local/ollama /usr/local/bin/ollama
87
+
88
+ rm -rf "${tmpdir}"
89
+ trap - EXIT
90
+ else
91
+ install_binary_from_tar \
92
+ "${OLLAMA_DOWNLOAD_BASE}.tgz" \
93
+ "bin/ollama" \
94
+ "ollama"
95
+ fi
96
+ fi
97
+
98
+ export PATH="/usr/local/bin:/usr/bin:/bin:${PATH}"
99
+
100
+ if ! command_exists ollama; then
101
+ echo "❌ Ollama CLI install completed but the binary is still not on PATH"
102
+ exit 1
103
+ fi
104
+
105
+ echo "✓ Ollama CLI installed: $(ollama --version)"
106
+ echo "ℹ️ OLLAMA_HOST is set to ${OLLAMA_HOST:-http://ollama:11434} — all commands target the sidecar."
@@ -0,0 +1,99 @@
1
+ #!/bin/bash
2
+ # Verification script for Ollama overlay
3
+ # Confirms Ollama CLI is installed and sidecar service is running and accessible
4
+
5
+ set -e
6
+
7
+ echo "🔍 Verifying Ollama overlay..."
8
+ echo ""
9
+
10
+ # Check Ollama CLI is installed
11
+ echo "1️⃣ Checking Ollama CLI..."
12
+ if ! command -v ollama &>/dev/null; then
13
+ echo " ❌ ollama CLI not found"
14
+ echo ""
15
+ echo "❌ Ollama overlay verification failed (ollama CLI is required but not installed)"
16
+ exit 1
17
+ fi
18
+ echo " ✅ ollama CLI found: $(ollama --version 2>/dev/null || echo 'version unavailable')"
19
+
20
+ # Check OLLAMA_HOST is set
21
+ echo ""
22
+ echo "2️⃣ Checking OLLAMA_HOST..."
23
+ if [[ -z "${OLLAMA_HOST:-}" ]]; then
24
+ echo " ⚠️ OLLAMA_HOST is not set — CLI will target localhost instead of the sidecar"
25
+ else
26
+ echo " ✅ OLLAMA_HOST=${OLLAMA_HOST}"
27
+ fi
28
+
29
+ # Check if curl is available
30
+ echo ""
31
+ echo "3️⃣ Checking curl availability..."
32
+ if ! command -v curl &> /dev/null; then
33
+ echo " ❌ curl not found"
34
+ echo ""
35
+ echo "❌ Ollama overlay verification failed (curl is required but not installed)"
36
+ exit 1
37
+ fi
38
+ echo " ✅ curl found"
39
+
40
+ # Check Ollama API
41
+ echo ""
42
+ echo "4️⃣ Checking Ollama service..."
43
+ OLLAMA_HOST="${OLLAMA_HOST:-http://ollama:11434}"
44
+ OLLAMA_READY=false
45
+
46
+ set +e
47
+ for i in {1..20}; do
48
+ if curl -sf "${OLLAMA_HOST}/api/tags" &> /dev/null; then
49
+ echo " ✅ Ollama service is ready"
50
+ OLLAMA_READY=true
51
+ break
52
+ fi
53
+ sleep 2
54
+ done
55
+ set -e
56
+
57
+ if [ "$OLLAMA_READY" = false ]; then
58
+ echo " ❌ Ollama service not ready after 40 seconds"
59
+ echo ""
60
+ echo "❌ Ollama overlay verification failed"
61
+ exit 1
62
+ fi
63
+
64
+ # Smoke-test CLI against the sidecar
65
+ echo ""
66
+ echo "5️⃣ Listing available models via CLI..."
67
+ set +e
68
+ ollama list && echo " ✅ ollama CLI can reach sidecar at ${OLLAMA_HOST}"
69
+ CLI_STATUS=$?
70
+ set -e
71
+
72
+ if [ $CLI_STATUS -ne 0 ]; then
73
+ echo " ⚠️ ollama CLI could not reach sidecar at ${OLLAMA_HOST}"
74
+ fi
75
+
76
+ # Show available models via REST API
77
+ echo ""
78
+ echo "6️⃣ Listing available models via API..."
79
+ TAGS_JSON=$(curl -sf "${OLLAMA_HOST}/api/tags")
80
+ CURL_STATUS=$?
81
+ if [ $CURL_STATUS -ne 0 ]; then
82
+ echo " ⚠️ Skipping model listing: failed to query /api/tags (curl exit code $CURL_STATUS)"
83
+ else
84
+ MODELS=$(printf '%s\n' "$TAGS_JSON" | grep -o '"name":"[^"]*"' | sed 's/"name":"//;s/"//')
85
+ if [ -n "$MODELS" ]; then
86
+ echo " ✅ Models available:"
87
+ echo "$MODELS" | while read -r model; do
88
+ echo " - $model"
89
+ done
90
+ else
91
+ echo " ℹ️ No models pulled yet. Use 'ollama pull <model>' to download a model."
92
+ fi
93
+ fi
94
+
95
+ echo ""
96
+ echo "✅ Ollama overlay verification complete"
97
+ echo " API endpoint: ${OLLAMA_HOST}"
98
+ echo " Docs: https://ollama.com/library"
99
+
@@ -0,0 +1,5 @@
1
+ # Open WebUI Configuration
2
+ OPEN_WEBUI_VERSION={{cs.OPEN_WEBUI_VERSION}}
3
+ OPEN_WEBUI_PORT={{cs.OPEN_WEBUI_PORT}}
4
+ OLLAMA_BASE_URL={{cs.OLLAMA_BASE_URL}}
5
+ WEBUI_SECRET_KEY={{cs.WEBUI_SECRET_KEY}}
@@ -0,0 +1,162 @@
1
+ # Open WebUI Overlay
2
+
3
+ Adds [Open WebUI](https://github.com/open-webui/open-webui) as a Docker Compose service, providing a polished browser-based chat interface for Ollama and other OpenAI-compatible LLM backends.
4
+
5
+ ## Features
6
+
7
+ - **Browser-based chat UI** — Full-featured conversational interface for local LLMs at `http://localhost:3000`
8
+ - **Ollama integration** — Pre-configured to connect to the `ollama` sidecar when the `ollama` overlay is also selected
9
+ - **Multi-model support** — Switch between different Ollama models from the UI without CLI commands
10
+ - **Conversation history** — Persists chat history in a named Docker volume across container rebuilds
11
+ - **OpenAI-compatible** — Works with any backend that speaks the OpenAI Chat Completions API
12
+ - **Port 3000** — Web interface auto-forwarded and opened in the browser
13
+
14
+ ## How It Works
15
+
16
+ Open WebUI runs as a Docker Compose service (`open-webui`) alongside your devcontainer. It connects to the Ollama service (or any OpenAI-compatible API) using the `OLLAMA_BASE_URL` environment variable.
17
+
18
+ **Service configuration:**
19
+
20
+ - Image: `ghcr.io/open-webui/open-webui:main`
21
+ - Network: `devnet` (shared with devcontainer and ollama)
22
+ - Port: `3000` on the host, mapped to `8080` inside the container
23
+ - Volume: `open-webui-data` for persistent chat history and settings
24
+
25
+ When used together with the `ollama` overlay, the stack looks like:
26
+
27
+ ```
28
+ devcontainer ─── open-webui (port 3000) ─┐
29
+ ├── devnet
30
+ ollama (port 11434) ─────┘
31
+ ```
32
+
33
+ Open WebUI reads `OLLAMA_BASE_URL` to find the Ollama API. When the `ollama` overlay is selected, this is pre-set to `http://ollama:11434`.
34
+
35
+ ## Common Commands
36
+
37
+ ### Web Interface
38
+
39
+ ```bash
40
+ # Open the web UI (auto-forwarded to localhost:3000)
41
+ # Navigate to http://localhost:3000 in your browser
42
+
43
+ # Check service status
44
+ docker compose ps open-webui
45
+
46
+ # View logs
47
+ docker compose logs open-webui
48
+ docker compose logs -f open-webui
49
+
50
+ # Restart the service
51
+ docker compose restart open-webui
52
+ ```
53
+
54
+ ### Using with Ollama
55
+
56
+ ```bash
57
+ # Pull a model with the Ollama CLI (still available in devcontainer)
58
+ ollama pull llama3.2
59
+
60
+ # The model will automatically appear in the Open WebUI model picker
61
+ # Visit http://localhost:3000 and start chatting
62
+ ```
63
+
64
+ ### REST API
65
+
66
+ Open WebUI exposes an OpenAI-compatible REST API at `http://localhost:3000/api`:
67
+
68
+ ```bash
69
+ # List available models via Open WebUI API
70
+ curl http://localhost:3000/api/models
71
+
72
+ # Chat completion via OpenAI-compatible endpoint
73
+ curl http://localhost:3000/api/chat/completions \
74
+ -H "Content-Type: application/json" \
75
+ -d '{
76
+ "model": "llama3.2",
77
+ "messages": [{"role": "user", "content": "Hello!"}]
78
+ }'
79
+ ```
80
+
81
+ ## Configuration
82
+
83
+ ### Environment Variables
84
+
85
+ Copy `.devcontainer/.env.example` to `.devcontainer/.env` and customize:
86
+
87
+ | Variable | Default | Description |
88
+ | -------------------- | --------------------- | ------------------------------------------------ |
89
+ | `OPEN_WEBUI_VERSION` | `main` | Open WebUI Docker image tag |
90
+ | `OPEN_WEBUI_PORT` | `3000` | Host port for the web interface |
91
+ | `OLLAMA_BASE_URL` | `http://ollama:11434` | Base URL of the Ollama API |
92
+ | `WEBUI_SECRET_KEY` | `supersecret` | Secret key for session signing (change for prod) |
93
+
94
+ ### Connecting to a Different LLM Backend
95
+
96
+ If you are not using the `ollama` overlay but have another OpenAI-compatible API available, set `OLLAMA_BASE_URL` in `.devcontainer/.env`:
97
+
98
+ ```bash
99
+ # Point at a remote OpenAI-compatible server
100
+ OLLAMA_BASE_URL=http://my-llm-server:8000
101
+ ```
102
+
103
+ ## Use Cases
104
+
105
+ - **Local AI chat** — Interact with local models via a polished UI instead of the CLI
106
+ - **Model comparison** — Switch between models mid-conversation to compare quality
107
+ - **Prompt engineering** — Iterate on system prompts and parameters interactively
108
+ - **Offline AI workflows** — Full AI chat capability without internet access or API costs
109
+ - **Team demos** — Share the forwarded port URL with teammates for collaborative testing
110
+
111
+ **Integrates well with:**
112
+
113
+ - `ollama` — Provides the LLM backend; Open WebUI connects automatically
114
+ - `cuda` — GPU acceleration for faster Ollama inference
115
+ - `python` — Build integrations using the Open WebUI REST API
116
+
117
+ ## Troubleshooting
118
+
119
+ ### UI Not Loading
120
+
121
+ ```bash
122
+ # Check the service is running
123
+ docker compose ps open-webui
124
+
125
+ # View startup logs
126
+ docker compose logs open-webui
127
+
128
+ # Restart the service
129
+ docker compose restart open-webui
130
+ ```
131
+
132
+ ### No Models Available
133
+
134
+ If the model picker in Open WebUI shows no models:
135
+
136
+ 1. Ensure the `ollama` overlay is selected and the Ollama service is running
137
+ 2. Pull a model with `ollama pull llama3.2` from the devcontainer terminal
138
+ 3. Refresh the Open WebUI page
139
+
140
+ ```bash
141
+ # Verify Ollama is reachable from within the Open WebUI container
142
+ docker compose exec open-webui curl -sf http://ollama:11434/api/tags
143
+ ```
144
+
145
+ ### Port Conflict on 3000
146
+
147
+ ```bash
148
+ # .devcontainer/.env
149
+ OPEN_WEBUI_PORT=3001
150
+ ```
151
+
152
+ ## References
153
+
154
+ - [Open WebUI GitHub](https://github.com/open-webui/open-webui)
155
+ - [Open WebUI Documentation](https://docs.openwebui.com)
156
+ - [Open WebUI Docker Hub](https://ghcr.io/open-webui/open-webui)
157
+
158
+ **Related Overlays:**
159
+
160
+ - [`ollama`](../ollama/README.md) — Local LLM inference server (recommended companion)
161
+ - [`cuda`](../cuda/README.md) — NVIDIA GPU acceleration for faster inference
162
+ - [`python`](../python/README.md) — Python SDK for building integrations
@@ -0,0 +1,14 @@
1
+ {
2
+ "$schema": "https://raw.githubusercontent.com/devcontainers/spec/main/schemas/devContainer.base.schema.json",
3
+ "runServices": ["open-webui"],
4
+ "forwardPorts": [3000],
5
+ "portsAttributes": {
6
+ "3000": {
7
+ "label": "Open WebUI",
8
+ "onAutoForward": "openBrowser"
9
+ }
10
+ },
11
+ "containerEnv": {
12
+ "OPEN_WEBUI_PORT": "3000"
13
+ }
14
+ }
@@ -0,0 +1,23 @@
1
+ version: '3.8'
2
+
3
+ services:
4
+ open-webui:
5
+ image: ghcr.io/open-webui/open-webui:${OPEN_WEBUI_VERSION:-{{cs.OPEN_WEBUI_VERSION}}}
6
+ restart: unless-stopped
7
+ volumes:
8
+ - open-webui-data:/app/backend/data
9
+ environment:
10
+ OLLAMA_BASE_URL: ${OLLAMA_BASE_URL:-{{cs.OLLAMA_BASE_URL}}}
11
+ WEBUI_SECRET_KEY: ${WEBUI_SECRET_KEY:-{{cs.WEBUI_SECRET_KEY}}}
12
+ ports:
13
+ - '${OPEN_WEBUI_PORT:-{{cs.OPEN_WEBUI_PORT}}}:8080'
14
+ extra_hosts:
15
+ - host.docker.internal:host-gateway
16
+ networks:
17
+ - devnet
18
+
19
+ volumes:
20
+ open-webui-data:
21
+
22
+ networks:
23
+ devnet:
@@ -0,0 +1,38 @@
1
+ id: open-webui
2
+ name: Open WebUI
3
+ description: Browser-based chat UI for Ollama and OpenAI-compatible LLM backends
4
+ category: dev
5
+ supports:
6
+ - compose
7
+ requires: []
8
+ suggests:
9
+ - ollama
10
+ conflicts: []
11
+ tags:
12
+ - dev
13
+ - ai
14
+ - llm
15
+ - ui
16
+ - chat
17
+ - openwebui
18
+ ports:
19
+ - port: 3000
20
+ service: open-webui
21
+ protocol: http
22
+ path: /
23
+ description: Open WebUI web interface
24
+ onAutoForward: openBrowser
25
+ parameters:
26
+ OPEN_WEBUI_VERSION:
27
+ description: Open WebUI Docker image tag
28
+ default: main
29
+ OPEN_WEBUI_PORT:
30
+ description: Host port mapped to the Open WebUI web interface (8080 inside container)
31
+ default: '3000'
32
+ OLLAMA_BASE_URL:
33
+ description: Base URL of the Ollama API (leave default when using the ollama overlay)
34
+ default: 'http://ollama:11434'
35
+ WEBUI_SECRET_KEY:
36
+ description: Secret key for Open WebUI session signing (change for any shared environment)
37
+ default: change-me-please
38
+ sensitive: true
@@ -0,0 +1,6 @@
1
+ # pgvector Configuration
2
+ PGVECTOR_VERSION={{cs.PGVECTOR_VERSION}}
3
+ PGVECTOR_DB={{cs.PGVECTOR_DB}}
4
+ PGVECTOR_USER={{cs.PGVECTOR_USER}}
5
+ PGVECTOR_PASSWORD={{cs.PGVECTOR_PASSWORD}}
6
+ PGVECTOR_PORT={{cs.PGVECTOR_PORT}}