feat: Add Railway Integration#3024
Conversation
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
…railway-integration
|
@shambel-amare looking good. Thanks for opening the PR. Before we continue, please make sure to: 1/ Attach a video in the PR description that shows how the new components are working These steps are covered in more detail in this document: |
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
- setup early skips metadata update on config change Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
web_src/src/pages/workflowv2/mappers/railway/on_deployment_event.ts
Outdated
Show resolved
Hide resolved
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
…sing Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
@darkofabijan i will be creating the video shortly, however i have a question on attaching Issue on this PR. is it the core team who create Issues? or is it fine if i create it? |
|
@shambel-amare the issue already exists: #2910 |
project scoped token required, updated docs with proper description Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
|
@shambel-amare here are some ux/functional notes: Integration form
Trigger component
Action component
|
@AleksandarCole when you say |
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
…railway-integration
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
…railway-integration
|
Hi @shambel-amare as discussed on Discord, we want to have polling to get the live status of the deployment until its finished. Regarding other issues, with the latest changes: Seems like trigger component stopped working - it's not showing that webhook setup form anymore And there seems to be another regression with the icon that was displaying properly before, but doesn't now: |
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
…railway-integration
Signed-off-by: Shambel Amare <shambelamare2006@gmail.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
| err = ctx.ExecutionState.SetKV("deployment_id", deploymentID) | ||
| if err != nil { | ||
| return fmt.Errorf("failed to store deployment ID: %w", err) | ||
| } |
There was a problem hiding this comment.
Deployment ID stored in KV but never retrieved
Low Severity
ctx.ExecutionState.SetKV("deployment_id", deploymentID) writes to the execution KV store, but no code in the Railway integration ever calls FindExecutionByKV or GetKV with this key. The TriggerDeploy.HandleWebhook is a no-op, so the KV is never used for webhook-to-execution matching. The poll action reads the deployment ID from ctx.Metadata.Get() instead. This appears copied from the Render Deploy pattern (which does use KV for webhook matching) but is unnecessary here since Railway relies solely on polling.







Implements #2910
Summary
This PR adds the Railway integration to SuperPlane, enabling users to deploy and monitor Railway applications.
What Changed
Backend (
pkg/integrations/railway/)railway.go): API token authentication with project cachingtrigger_deploy.go): Component to trigger deployments for a service in an environmenton_deployment_event.go): Webhook-based trigger for Railway deployment status changes (succeeded, failed, crashed, etc.)client.go): Railway API client using GraphQLwebhook_handler.go): Handles incoming Railway webhooksFrontend (
web_src/src/pages/workflowv2/mappers/railway/)Documentation
Why
Railway is a popular deployment platform, and this integration allows SuperPlane users to:
How
Video 1
Video 2
Uses Railway's GraphQL API (
https://backboard.railway.com/graphql/v2) with Bearer token authProjects are cached in integration metadata during sync for efficient resource listing
Webhook-based triggers require manual webhook configuration in Railway (Railway doesn't support programmatic webhook creation)
Supports filtering deployment events by status (succeeded, failed, crashed, building, etc.)
Test Plan