[Rails + Postgres] How can I reset my database, as well as seed it?

This is not being used yet, so I know the risks or resetting, but I can’t seem to figure out how to run db:reset. Is the only solution upgrading to a paid plan to access the shell?

Thank you in advance!

Hi Jeff,
On the free plan you’d need to use jobs to trigger the reset via our API:

curl --request POST 'https://api.render.com/v1/services/<service-ID>/jobs' \
    --header 'Authorization: Bearer API_TOKEN' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "startCommand": "rake db:reset"

John B

Thanks John! If I upgrade to paid, then can I just run ssh commands (like heroku) to access a lot more things?

Correct, paid plans have shell tab access and also you can use ssh to connect to the instance,


1 Like

Where do I find the ID above? I created an API key, but I can’t seem to find that.

If you go to your dashboard > select the service > Settings, you can see the ID there a few times. Deploy Hook has it in the url such as https://api.render.com/deploy/{service-ID}?key=....

I do think it should simply be shown at the top with the other details.

Yep, the serviceID is always in the URL when looking at a service in thedashboard, it would be prefixed srv-

John B