Skip to content

Latest commit

 

History

History
23 lines (19 loc) · 1.86 KB

deploy.md

File metadata and controls

23 lines (19 loc) · 1.86 KB

Putting Your Application Online

What is deployment?

Your app is live. Great! But right now, it runs on your local machine only. If you want others to see and use it, you'll need to deploy it. The quickest way to deploy your app is to push it to Heroku using Git.

Deploying to Heroku

  1. First, make sure you're in the global-growth directory. (cd global-growth if necessary.) Now run git init to create an empty Git repository. git init
  2. Heroku will look for a text file called Procfile to tell it how to deploy the app. Create one with the command echo "web: lein ring server-headless $PORT" > Procfile.
  3. Heroku will receive only the files you have committed to your local repo, so it's time to add your files to Git and commit these changes to the repo you've just created. Run git status. This command shows you the files you've modified but have yet to stage for a commit. Run the following commands to stage all your files and commit the corresponding changes:
    git add .
    

git commit -m "[Your commit message here]" Your commit message should refer to the changes you've made. Something like "Add functions to retrieve indicator data" would work.

  1. As you did in the setup steps, run heroku create. You'll see something like this: heroku create

  2. Push your changes to Heroku by running git push heroku master. This command takes all the changes you've committed locally and pushes them to Heroku.

  3. Run heroku open. Your application should open in your browser. If that doesn't happen, open a browser and visit the URL which heroku create returned. Profit!