feat: Add Railway integration#5083
Draft
12458 wants to merge 8 commits into
Draft
Conversation
Signed-off-by: Shang En Sim <6071014+12458@users.noreply.github.com>
Signed-off-by: Shang En Sim <6071014+12458@users.noreply.github.com>
Signed-off-by: Shang En Sim <6071014+12458@users.noreply.github.com>
Signed-off-by: Shang En Sim <6071014+12458@users.noreply.github.com>
Signed-off-by: Shang En Sim <6071014+12458@users.noreply.github.com>
Signed-off-by: Shang En Sim <6071014+12458@users.noreply.github.com>
|
👋 Commands for maintainers:
|
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.
This PR implements the base Railway integration (#2910) using the new wizard-based setup flow.
What changed
Backend (
pkg/integrations/railway/)client.go): Wrapped the Railway GraphQL API (v2 backboard), adding methods forVerify,ListWorkspaces,ListProjects,GetProjectDetails,TriggerDeploy(redeployment),GetDeployment(polling check), and rule management.setup_provider.go): Multi-step wizard allowing capability selection, Workspace Token input, validation, and secure secrets storage.webhook_handler.go): Dynamically loads project details to extract the correct workspace ID, and automatically creates the platform notification rule on Railway (notificationRuleCreate).on_deployment.go): Subscribes to and parses Railway platform notifications (including nested resource payloads) to emit status updates.trigger_deploy.go): Triggers service redeployment and runs a polling loop checker. Emits to thesuccessorfailedchannel depending on terminal states.pkg/registryimports/registryimports.go): Registered the railway integration package.Frontend
railway.svg): Added the official Railway branding logo.integrationIconMaps.ts): Mapped"railway"to the SVG logo.web_src/src/pages/workflowv2/mappers/railway/): Added mappers (base.ts,on_deployment.ts,trigger_deploy.ts,index.ts) for custom styling, labels, configuration details, execution outcomes, and timelines.web_src/src/pages/workflowv2/mappers/index.ts): Integrated the mappers into the main workflow v2 canvas list.Documentation (
docs/components/Railway.mdx)make gen.components.docs.Why
To enable SuperPlane workflows to redeploy services and respond to deployment state changes on the Railway platform.
How
Deployment.*statuses) are mapped to standard unguessable UUID webhook paths.SUCCESSor failure/cancellation statuses (FAILED,CRASHED,REMOVED,SKIPPED,SLEEPING).Verification
pkg/integrations/railway.