This project is used to configure a Postgres database on railway.app to be used with Prisma Pulse. This enables you to quickly set up a database without having to do any configuration. Click the Deploy on Railway
button above to get started.
Pulse is currently in Early Access. Please sign up here or join our Discord and reach out to a Developer Advocate.
- Click on the service called
restart-db-then-delete-me
- You will see a list of deployments under the Deployments tab.
- Click the most recent build's View Logs button.
- Click on the Deploy Logs tab.
If the service ran correctly, you should see a message in the logs that says "All done please restart the database" along with your
DATABASE_URL
connection string. - Copy the
DATABASE_URL
connection string and save it for later. - Close the logs view with the X in the top right corner of the opened drawer.
- Navigate to the settings tab of the
restart-db-then-delete-me
service. - Scroll down to the bottom and click the red Delete Service from All Environments button.
Note: If you would like to use this service and the corresponding repo to create a new Pulse project. You can by cloning the repo from your GitHub account to your local machine.
- Once you have cloned the repository, you can run the following command.
rm config-db.ts
- Then remove the script
start: ts-node config-db.ts
from thescripts
object in thepackage.json
file.This is to prevent the script from running every time you push up to the repo associated with the
restart-db-then-delete-me
service.
- Once you have cloned the repository, you can run the following command.
- Go into your project on the railway dashboard
- Click on the Postgres database
- Navigate to the Deployments tab
- Click the dropdown for your current deployment, click Restart
- Go to your Prisma Data Platform dashboard
- Click on the project you want to add Pulse to (or create a new one)
- Click on Configure Pulse
- Paste in the connection string from the railway dashboard
The connection string can be found by clicking on the Postgres database and navigating to the Connect tab, then clicking the copy icon next to
DATABASE_URL
Once you have done that, you will need to wait for Pulse to establish the connection. This can take a few minutes.
Now you can follow the Pulse documentation to get started using Pulse in your projects.