You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+48-1
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,7 @@ composer install --prefer-dist
32
32
npm install
33
33
```
34
34
35
-
### Database Setup
35
+
### Database setup
36
36
37
37
Edit `.env.example` according to your environment and save as `.env`.
38
38
An application key can be generates with the command `php artisan key:generate`.
@@ -71,6 +71,53 @@ Now you can browse the site [http://localhost:8080](http://localhost:8080).
71
71
- NPM
72
72
- MySQL
73
73
74
+
## Heroku deployment
75
+
76
+
### Unignore some files
77
+
78
+
You should remove `.env` and `composer.lock` from `.gitignore`.
79
+
80
+
#### .env
81
+
82
+
Set up your `.env` file like described in “Database setup” above.
83
+
84
+
### Heroku buildpacks
85
+
86
+
You will need to add custom buildpacks for Heroku. Create `.buildpacks` and paste:
87
+
88
+
```
89
+
https://github.com/heroku/heroku-buildpack-php
90
+
https://github.com/heroku/heroku-buildpack-nodejs
91
+
```
92
+
93
+
### Procfile
94
+
95
+
```
96
+
web: vendor/bin/heroku-php-apache2 public/
97
+
```
98
+
99
+
### NPM config
100
+
101
+
Your `package.json` should be changed to this:
102
+
103
+
```json
104
+
{
105
+
"private": true,
106
+
"devDependencies": {
107
+
"gulp": "^3.8.8"
108
+
},
109
+
"dependencies": {
110
+
"laravel-elixir": "^3.0.0",
111
+
"gulp": "^3.8.8"
112
+
},
113
+
"scripts": {
114
+
"postinstall": "gulp"
115
+
}
116
+
}
117
+
```
118
+
119
+
The `scripts``postinstall` part is the important here, this will generate the resources like JS and CSS files.
120
+
74
121
Have fun! Any feedback is welcome. Use [Issues](https://github.com/Zemke/starter-laravel-angular/issues) or [Twitter](https://twitter.com/FlorianZemke). My Twitter handle is @FlorianZemke. I’m looking forward to talk to you.
0 commit comments