@renderinc/heroku-import
v4.0.2
Published
Heroku CLI plugin to migrate a Heroku app, PostgreSQL DB, and Redis to Render
Downloads
48
Keywords
Readme
heroku-import
Heroku CLI plugin to migrate a Heroku app, PostgreSQL DB, and Redis to Render
This plugin helps you migrate your apps and databases from Heroku to Render. It will perform the following steps.
- Gather information about the specified Heroku app
- Create a
render.yaml
andDockerfile.render
describing your app and database deployment in a format compatible with Render. - Give you instructions for how to use the generated
render.yaml
to deploy your service to Render and create PostgreSQL and Redis databases on Render as needed by your app.
Full documentation is available at https://render.com/docs/migrate-from-heroku
Note: This plugin will NOT modify your Heroku app in any way.
Usage
$ heroku plugins:install @renderinc/heroku-import
$ heroku render:import --app salty-waters-73797
=== Gathering information about Heroku app
Verifying Heroku app exists and CLI is logged in... ✔️
Verifying app is using a single, official Heroku buildpack... ✔️
Getting stack image... heroku-20
Getting and translating plan... Heroku Hobby $7/mo --> Render Starter $7/mo
Getting instance count... 1
Getting custom domains... 1 custom domain(s)
Getting environment variables... 7 environment variable(s)
Getting add-ons... 1 add-on(s)
? Select addons to import. postgresql-polished-30455 using hobby-dev plan
Create render.yaml file and Dockerfile.render? This will overwrite any existing files with the same name. (y/n): y
Generating render.yaml file... done
Generating Dockerfile.render... done
=== Environment variables excluded from render.yaml
The following environment variables were not included in the generated
render.yaml file because they potentially contain secrets. You may need to
manually add them to your service in the Render Dashboard.
- DATABASE_URL: postgres://user:[email protected]:5432/dbname
- SECRET_KEY_BASE: s3cr3t
=== Follow these steps to complete import of service(s) and database(s) to Render
1. Add, commit, and push the generated render.yaml and Dockerfile.render to GitHub or GitLab.
2. Go to https://dashboard.render.com/select-repo?type=blueprint
3. Search for and select this repository.
4. Verify the plan showing the resources that Render will create, and
then click 'Create New Resources'.
5. After the resources are deployed, you may need to manually add
the above environment variables to your Web Service in the Render Dashboard.
They were not included in the generated render.yaml because they potentially
contain secrets.
$ heroku render:import --help
Create a Dockerfile and render.yaml from an app deployed to Heroku
USAGE
$ heroku render:import
OPTIONS
-a, --app=app (required) name of Heroku app
DESCRIPTION
This Heroku CLI plugin gathers information about a deployed Heroku app and
its add-ons and saves that information in a render.yaml file. It then generates
a Dockerfile which can be used along with the render.yaml file to deploy the
app and its PostgreSQL databases and/or Redis instances on Render.
EXAMPLE
$ heroku render:import --app salty-waters-73797
Development
The Heroku CLI must already be installed.
- Clone this repo
cd
into it and runheroku plugins:link
Now when you run heroku render:import
, it will run the code from this directory on your local machine.