You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature: reusable OAuth/MCP agent connector with GroundControl deployment tools #81
RentAWeekend Surface work is currently blocked operationally when the operator is away from a desktop/VPS terminal. GroundControl already owns the VPS/deployment boundary, so expose a narrow, authenticated remote MCP surface that ChatGPT and other MCP clients can connect to using the familiar provider login/consent flow.
This is an enabling layer for RentAWeekend first, not a product-direction change.
Goal
Build a portable agent-connect layer that can later be extracted/bundled for other Serendepify projects. GroundControl is the reference host and RentAWeekend is the first acceptance workload.
Authentication / authorization
Preserve the existing GroundControl gc_token login and requireAuth() flow.
OAuth Authorization Code + S256 PKCE for delegated clients.
RFC 9728 protected-resource metadata and WWW-Authenticate challenge from /mcp.
Support current MCP authorization discovery. Prefer Client ID Metadata Documents (CIMD) for the 2026-07-28 profile; keep standards-compatible fallback registration only where needed for client compatibility.
Scope grants to the authenticated GroundControl user and continue enforcing GroundControl RBAC on every operation.
Never expose VPS credentials, environment secret values, or unrestricted shell access.
First MCP tool surface
Read:
deployment.list
deployment.inspect
deployment.logs
deployment.health
Write:
deployment.redeploy
All host operations must go through the existing execOnVps() / deployment abstractions per AGENTS.md.
Acceptance test: RentAWeekend
From ChatGPT/custom MCP client:
Connect GroundControl.
Browser opens GroundControl login/consent.
User authenticates and approves requested scopes.
Client can list/inspect RentAWeekend and read its logs/health.
A redeploy request can deploy latest RentAWeekend main through GroundControl without exposing SSH credentials.
Disconnect/revoke removes future MCP access.
Existing GroundControl browser auth and UI continue to work unchanged.
Portability boundary
Keep OAuth grant/token logic, scope definitions, protected-resource discovery, and MCP bearer validation isolated from GroundControl-specific deployment executors so this can later become a package or sidecar.
interrupted non-reconcilable mutations become uncertain instead of being replayed
Agents UI for endpoint, connection guidance, grants and revocation
Production migration and deployment are green.
Keep this issue open for the remaining acceptance test: connect a real ChatGPT/custom MCP client, complete OAuth consent, inspect/redeploy an approved workload, disconnect/reconnect, and retrieve final operation evidence. Connector reliability is deliberately parked in #86.
ChatGPT dev-mode acceptance uncovered a real discovery regression after OAuth succeeded: the app showed connected but "No app actions available yet" and Refresh Actions failed.
Keep #81 open until the already-connected ChatGPT dev app is refreshed/reconnected and successfully invokes deployment.list/health and a durable redeploy end-to-end.
Live ChatGPT usage exposed another useful read-side gap: the agent could verify managed environment activity but could not answer whether a named key such as PAYSTACK_SECRET_KEY was configured without secret access.
2026-09-20 long-lived ChatGPT access regression found and fixed in #102 / main commit 92a1ac5.
Symptom:
Ground Control worked after initial OAuth, then hours later ChatGPT reported it no longer had access.
Root cause:
GC access tokens expire after 1 hour.
The refresh-token endpoint required client_id on every refresh request.
That is too strict for public PKCE clients using token_endpoint_auth_method=none; OAuth refresh requests need refresh_token, while client authentication/identity requirements depend on client type.
A missing client_id was rejected before the stored refresh token was rotated/revoked.
Fix:
refresh_token remains required
client_id may be omitted only for registered public clients with tokenEndpointAuthMethod=none
if client_id is supplied, it must match exactly
clients requiring token-endpoint authentication still cannot omit identity
regression tests cover all three cases
Production deploy passed:
container healthy
public login smoke passed
public MCP discovery smoke passed
Existing ChatGPT refresh credentials should remain usable unless the client already discarded them and requires one reconnect.
Activity
teckedd-code2save commentedon Sep 18, 2026
Implementation landed in #87 / main commit 41ea9b1.
Completed:
Production migration and deployment are green.
Keep this issue open for the remaining acceptance test: connect a real ChatGPT/custom MCP client, complete OAuth consent, inspect/redeploy an approved workload, disconnect/reconnect, and retrieve final operation evidence. Connector reliability is deliberately parked in #86.
teckedd-code2save commentedon Sep 18, 2026
ChatGPT dev-mode acceptance uncovered a real discovery regression after OAuth succeeded: the app showed connected but "No app actions available yet" and Refresh Actions failed.
Fixed in #89 / main commit 0b8d4aa:
Production deploy passed, including:
"MCP discovery smoke passed: https://groundcontrol.serendepify.com/mcp"
Keep #81 open until the already-connected ChatGPT dev app is refreshed/reconnected and successfully invokes deployment.list/health and a durable redeploy end-to-end.
teckedd-code2save commentedon Sep 18, 2026
Live ChatGPT usage exposed another useful read-side gap: the agent could verify managed environment activity but could not answer whether a named key such as PAYSTACK_SECRET_KEY was configured without secret access.
Implemented in #90 / main commit ed79aca:
Production deploy passed and MCP discovery smoke passed.
teckedd-code2save commentedon Sep 18, 2026
Live ChatGPT acceptance progressed further on 2026-09-18.
Confirmed end-to-end from ChatGPT web:
This proves the write/durable-operation path from ChatGPT -> OAuth -> MCP -> AgentOperation -> deployment execution -> verification -> structured evidence.
Remaining acceptance items before closing #81:
teckedd-code2save commentedon Sep 20, 2026
2026-09-20 long-lived ChatGPT access regression found and fixed in #102 / main commit 92a1ac5.
Symptom:
Root cause:
Fix:
Production deploy passed:
Existing ChatGPT refresh credentials should remain usable unless the client already discarded them and requires one reconnect.