-
Notifications
You must be signed in to change notification settings - Fork 188
Add native authenticated MCP support to TrailBase #262
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
eaa8ceb
bd1e4dc
60527ea
92a1f2b
143bcc0
2516543
bab7cfb
578769b
8b4a05b
ebc3a23
0f8dedd
f3baaf5
7a5a1b7
7ca558a
1f145d4
168635e
fefa6da
6235a81
0ec3e72
beb571e
81c3f5c
1b7c1d4
601f80b
1610ef2
b2c7e93
246f75a
69bcb58
eaa6ea9
2c27a1f
286111a
5bf2123
9401046
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| #!/usr/bin/env sh | ||
| set -eu | ||
|
|
||
| SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd) | ||
| REPO_ROOT=$(CDPATH= cd -- "${SCRIPT_DIR}/.." && pwd) | ||
| PROTOBUF_DIR="${REPO_ROOT}/.dev-tools/protobuf" | ||
|
|
||
| export LD_LIBRARY_PATH="${PROTOBUF_DIR}/usr/lib/x86_64-linux-gnu${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}" | ||
| exec "${PROTOBUF_DIR}/usr/bin/protoc" \ | ||
| -I"${PROTOBUF_DIR}/usr/include" \ | ||
| "$@" | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same as above? |
||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -141,6 +141,20 @@ trail components add trailbase/auth_ui | |
| endpoints, e.g. | ||
| [http://localhost:4000/\_/auth/login](http://localhost:4000/_/auth/login). | ||
|
|
||
| ## MCP | ||
|
|
||
| This fork includes an optional native MCP server in the main TrailBase binary. | ||
| It uses TrailBase administrator login through OAuth and runs on the same port as | ||
| TrailBase—no sidecar container or copied bearer token is required. | ||
|
|
||
| ```sh | ||
| trail --public-url https://trailbase.example.com run --mcp | ||
| ``` | ||
|
|
||
| Connect an OAuth-capable MCP client to | ||
| `https://trailbase.example.com/mcp`. See the [MCP guide](mcp/README.md) for IDE, | ||
| Docker, Portainer, reverse-proxy, authentication, and security configuration. | ||
|
|
||
| ## Building | ||
|
|
||
| If you have all the necessary build dependencies (Rust, node.js, geos, | ||
|
|
@@ -162,6 +176,15 @@ pnpm install | |
| cargo build --bin trail | ||
| ``` | ||
|
|
||
| On Debian/Ubuntu-style systems without sudo access to install build packages, | ||
| this fork can populate the repo-local `.dev-tools/` cache used by | ||
| `.cargo/config.toml`: | ||
|
|
||
| ```sh | ||
| scripts/bootstrap-local-dev-tools.sh | ||
| cargo check --workspace --all-targets | ||
| ``` | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok, so the above files are not artifacts. This is a bit surprising since, I would expect most devs to have access to their machines (seems like a reasonable requirement). Otherwise, this is also very deb centric. If you don't have full access, wouldn't one rather develop inside a container? Would love to hear more about the reasoning. |
||
|
|
||
| Alternatively, if you want to build a Docker image or don't want to deal with | ||
| build dependencies, you can simply run: | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm going to assume that his is an artifact