Last active
October 16, 2016 10:48
-
-
Save duwaljyoti/c03a96987c9fd9495d28a62da208bc11 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
First of all one needs to have a heroku account. | |
one can got into https://www.heroku.com/ and create a free account | |
(make sure to have php and composer installed) | |
install the heroku CLI by typing in | |
wget -O- https://toolbelt.heroku.com/install-ubuntu.sh | sh | |
or you can choose other options according to your OS. | |
After installing Go inside of the laravel project | |
and type in your email and password after heroku login | |
now create a file name Procfile without any extension or anything.. and type in | |
web: vendor/bin/heroku-php-apache2 public | |
and save it.. | |
now initialize a git repository by doing git init inside your laravel project | |
then type in git add . | |
then git commit -m "with your message" | |
now to create heroku app | |
type in | |
heroku create --buildpack https://github.com/heroku/heroku-buildpack-php app_name | |
(it creates a sort of a placeholder for your app..if you choose to keep the app_name empty heorku will assign a random name for your app | |
after that we need to set a random key..by hitting | |
php artisan key:generate | |
after that we need to config file by hitting | |
heroku config:set APP_KEY="random_key_generated_by_artisan_commad" | |
the final step now is git push heroku master... | |
this wil deploy your application.. | |
To see if its correctly deployed one needs to type in heroku open in the terminal which on succesful deployment will cause the newly deployed site on your default browser. | |
Detail Documentation can be found at https://devcenter.heroku.com/articles/getting-started-with-php#set-up | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment