yjyjyjy / with-heroku

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Razzle Heroku Deployment example

How to use

Create and start the example:
npx create-razzle-app --example with-heroku with-heroku

cd with-heroku
yarn start

Deploy to Heroku:

Heroku manages app deployments with Git so:

Setup Git:

git init
git add
git commit -m "Heroku deployment, first commit"

Setup Heroku:

  • Create a Heroku account
  • Install Heroku CLI and authenticate
  • Create Heroku app: heroku create
    • or heroku create <appname> if you want to specify an app name (checks for unique app name)
    • or heroku git:remote -a <appname> if you already created an App in the dashboard
  • Verify with git remote -v:
heroku	https://git.heroku.com/<appname>.git (fetch)
heroku	https://git.heroku.com/<appname>.git (push)

Deployment

👉 Please note

  • Heroku expects a yarn.lock file to be able to recognise yarn as your package manager and process the yarn commands - so make sure to run yarn install before deployment, and to commit the yarn.lock file.

Idea behind the example

This is a basic example of how to use razzle and deploy to Heroku with Git.

About


Languages

Language:JavaScript 92.6%Language:CSS 7.4%