Laravel deployer
Note Deployed Laravel folders will be organized same Rocketeer deployed, so this app could be used while using Rocketeer. If this is the first time you setup your project, so you need setup project folders by manual.
This will be: /var/www/project_name/github_name/{releases - shared - current}
Manual setup
Install requirement
$ sudo apt-get install git
$ curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
$ sudo apt-get install -y nodejs
$ npm install pm2 -g
Setting
- Git clone from Master branch
- Move to folder
node_deploy - Config
.envfilecp .env.example .envNote Go to Personal access tokens to get token for
GITHUB_AUTH_TOKEN - Install package:
$ npm install - Run in background:
$ pm2 start app.jsAuto setup

- Download bash file install.sh then move it to
/var/www/ - Change to
deployuser$ sudo su - deploy - Then run this file in
deployuser$ ./install.shBash file with su permission
- Download bash file sudo_install.sh then move it to
/var/www/ - Then run with sudo:
$ sudo ./sudo_install.sh
Nginx setup
- Use reverse proxy
#..... location ^~/socket.io/ { proxy_pass http://localhost:8001; #node port proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_redirect off; proxy_buffers 8 32k; proxy_buffer_size 64k; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $host; proxy_set_header X-NginX-Proxy true; } location /deploy { proxy_pass http://localhost:8001; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_redirect off; proxy_buffers 8 32k; proxy_buffer_size 64k; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $host; proxy_set_header X-NginX-Proxy true; } location ^~/nes.css/ { proxy_pass http://localhost:8001; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_redirect off; proxy_buffers 8 32k; proxy_buffer_size 64k; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $host; proxy_set_header X-NginX-Proxy true; auth_basic "off"; } #....!! Note !! If your project used Laravel echo or something else like socketIO, this will get conflict.
How to use

- Go to
https://yourdomain.com/deployto start deploy - Go to
https://yourdomain.com/deploy/edit-envto edit env file - Check pm2 at pm2.keymetrics.io
- Get Github auth token here
- Deployed Laravel folders will be organized same Rocketeer deployed