github PR integration. Is it automatic or do I have to manually create an instance and change the source to the PR?
davidatthehootapp
FREEOP

a month ago

Github copilot suggested Railway as the best solution to automatically create test instances for each PR and then after a day of troubleshooting told me to create an instance copied from production and change the Source "Branch connected to" to the PR branch. Not exactly auto.

I presume since there were all the settings to enable PRs that there must be an auto method that copilot can't troubleshoot.

What are the troubleshooting steps?

Solved$10 Bounty

Pinned Solution

mykal
PRO

a month ago

GitHub Actions are not required- I would suggest reading the docs not just blindly trusting the Claude on this one grin emoji

Using Environments | Railway Docs

  1. Go to Project Settings -> Environments tab,

  2. Click "Enable PR Environments",

  3. Optionally enable "Bot PR Environments" if you want Dependabot/Renovatebot PRs to also get preview environments

All you need to do is enable PR environments in your project. Once enabled, Railway will automatically create a temporary environment with a unique URL whenever a PR is opened. The environment is deleted when the PR is merged or closed. I use these all the time; definitely very useful and no real setup to be done after turning on the feature slightly_smiling_face emoji

2 Replies

mykal
PRO

a month ago

GitHub Actions are not required- I would suggest reading the docs not just blindly trusting the Claude on this one grin emoji

Using Environments | Railway Docs

  1. Go to Project Settings -> Environments tab,

  2. Click "Enable PR Environments",

  3. Optionally enable "Bot PR Environments" if you want Dependabot/Renovatebot PRs to also get preview environments

All you need to do is enable PR environments in your project. Once enabled, Railway will automatically create a temporary environment with a unique URL whenever a PR is opened. The environment is deleted when the PR is merged or closed. I use these all the time; definitely very useful and no real setup to be done after turning on the feature slightly_smiling_face emoji


bbhoss
FREE

a month ago

David, make sure that the Railway app has access to your repository containing the code. You can check this link: https://github.com/organizations/Hoot-AI-Robotics-Inc/settings/installations (I pulled your org name from above but you can go into the org settings and "Github Apps" and see if Railway is there, then click configure to ensure it has access to the repo you care about or all repos.

Railway will get notified about new PRs using this integration and use the checks, deployments, etc apis to work with the PR environments.


Status changed to Solved brody about 1 month ago


Loading...