Repository navigation
feat: expose the app-content bucket, MCP, OAuth and artifact retention [ENG-1739] - #31
Merged
Merged
Conversation
…n [ENG-1739] - api, changestreams-worker and write-worker read the app-content bucket (context shares, organization logos, session files) from APP_CONTENT_STORAGE_*, mapped to the PERMANENT_STORAGE_* the services read. .env.example reuses the artifact storage endpoint and credentials. - rustfs-init creates the app-content bucket with lifecycle rules scoped to the four share prefixes, and applies DC_RUSTFS_DELETE_ARTIFACTS_AFTER_DAYS to the artifact bucket (unset removes the rule). - MCP_ENABLED defaults to true. .env.example turns the OAuth provider and dynamic client registration on; an upgraded .env without them keeps OAuth off. OAuth needs https, or http on localhost or (for an evaluation) a .localhost name in OAUTH_HTTP_ALLOWED_HOSTS: Better Auth advertises an https issuer for any other http host. - The api verifies OAuth access tokens against http://localhost:4000. The default JWKS URL is on APP_BASE_URL, which the container cannot resolve for a .localhost name, so every token was rejected. - Drop SSO_SAML_SP_CERT_FILE: the API never read it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UhM4wHR2xPP8bbrkXGaqUD
|
| Topic | Details | ||||||
|---|---|---|---|---|---|---|---|
| App Content Storage | Map app-content settings to API, changestreams, and writer services, create the dedicated RustFS bucket, and manage scoped share and optional artifact lifecycle rules without deleting persistent logos or session files.Modified files (9)
Latest Contributors(1)
| ||||||
| MCP and OAuth Access | Enable and document authenticated remote MCP and OAuth endpoints, including defaults, registration, issuer and JWKS behavior, HTTP restrictions, origin configuration, and deployment off switches.Modified files (8)
Latest Contributors(1)
| ||||||
| Deployment Documentation | Update operator-facing deployment guidance and release notes to reflect the expanded object-storage model, removed SAML certificate setting, RustFS lifecycle behavior, and regenerated Compose configuration.Modified files (4)
Latest Contributors(1)
|
…UTH_JWKS_URL to .localhost setups [ENG-1739] - PERMANENT_STORAGE_* falls back to the same names in .env when APP_CONTENT_STORAGE_* is unset. The environment entries override env_file, so an .env that set PERMANENT_STORAGE_* directly got empty values. - rustfs-init rewrites only the lifecycle rules it owns, matched by ID, and keeps any others on both buckets. It deleted the artifact bucket's whole configuration when retention was unset, and replaced the app-content one. - The api no longer sets OAUTH_JWKS_URL. A real install fetches its signing keys from APP_BASE_URL as cloud does; the .localhost evaluation sets it to localhost in .env, since the container cannot resolve .localhost names. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UhM4wHR2xPP8bbrkXGaqUD
…o set OAUTH_JWKS_URL [ENG-1739] The CHANGELOG still said rustfs-init replaces both buckets' lifecycle configuration. OAUTH_JWKS_URL also applies when the container cannot reach or trust APP_BASE_URL. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UhM4wHR2xPP8bbrkXGaqUD
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Exposes the app-content bucket, remote MCP, the OAuth provider and artifact retention in the Docker Compose setup (ENG-1739).
The app-content bucket holds context shares, organization logos and session files. The services read it from
PERMANENT_STORAGE_*(ENG-1738), but nothing in Compose set those, so on-prem context sharing, logo editing and session file uploads were off.Changes
api,changestreams-workerandwrite-workermapAPP_CONTENT_STORAGE_*from.envtoPERMANENT_STORAGE_*. Each falls back toPERMANENT_STORAGE_*in.env, so an.envthat sets those directly keeps working: theenvironment:entries overrideenv_file..env.examplereuses the artifact storage endpoint and credentials, with bucketcurrents-app-content.rustfs-init:ai-context-share/,share-3d/,share-7d/andtrace-links/(2, 4, 8 and 8 days). They are never bucket-wide, because logos and session files live in the same bucket.DC_RUSTFS_DELETE_ARTIFACTS_AFTER_DAYSset, adds a bucket-wide expiry rule to the artifact bucket. When it's unset, removes that rule.MCP_ENABLEDdefaults totrue./mcpanswers 401 without a credential..env.examplesetsOAUTH_PROVIDER_ENABLED=trueand enables dynamic client registration..envwithout these lines keeps OAuth off.APP_BASE_URL, or http onlocalhost:OAUTH_PROVIDER_ENABLED=falsethere.OAUTH_HTTP_ALLOWED_HOSTSgets the API to start on such a host, but Better Auth'svalidateIssuerUrlthen advertises anhttps://issuer that the install doesn't serve. So the docs offer the variable only for a*.localhostname, as an evaluation option; Better Auth counts those as loopback.OAUTH_JWKS_URL: documented for the.localhostevaluation only, ashttp://localhost:4000/api/auth/jwks.APP_BASE_URLunless this is set.*.localhostname (ENOTFOUND), so without it every token is issued and then rejected at/mcp.APP_BASE_URL, as cloud does. Plainhttp://localhost:4000doesn't need it, since inside the container that address is the API.SSO_SAML_SP_CERT_FILEis removed. The API only readsSSO_SAML_SP_KEY_FILE, and the docs say to upload the certificate to the IdP.configuration.mdgets the new variables.object-storage.md(now "Use AWS S3 for Object Storage") gets the app-content bucket's IAM, CORS (PUTfor logo uploads) and lifecycle rules, plus artifact expiry on your own S3.quickstart.mdgets the second bucket and the OAuth/http note.[Unreleased].docker-compose.{full,database,cache}.ymlare regenerated. They matchsync-templates.shand passdocker compose config.Testing
On the generated
docker-compose.full.ymlwith images built from currentsmain(including ENG-1738), ports moved off the defaults:rustfs-init:delete-artifacts-after-days.0,00,007,-5,abcand7dexit 1.POST /v1/sessionsupload lands undercurrents-app-content/<orgId>/sessions/.DELETE /v1/sessions/<id>clears the prefix through the writer, and the session then answers 404./mcplists 43 tools.http://localhostis consistent, and dynamic client registration works.http://currents.localhost:14000with the two.localhostlines from.env.example, the full flow passes: sign-in, client registration, authorize, consent, token, then/mcpwith the token. WithoutOAUTH_JWKS_URL, the token is issued and/mcprejects it.http://currents.internalwith the host allowed, the API starts but advertiseshttps://currents.internal.docker compose configwith onlyPERMANENT_STORAGE_*in.envpasses them through to all three services; with both names set,APP_CONTENT_STORAGE_*wins.MCP_ENABLED=falsemakes/mcpanswer 503..envwithoutOAUTH_*serves no OAuth metadata (404), and MCP keeps working with keys.Related
Checklist
(fix|feat|chore): title [CSR-xxx]🤖 Generated with Claude Code
https://claude.ai/code/session_01UhM4wHR2xPP8bbrkXGaqUD