LaraSail - Set Sail with your Laravel app on Digital Ocean
Switch branches/tags
Nothing to show
Clone or download
Tony Lea
Latest commit d56865b Jun 4, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.larasail adding more documentation Jun 1, 2018
README.md Adding new content Jun 3, 2018
install Adding new content Jun 3, 2018

README.md

LaraSail

LaraSail is a CLI tool for Laravel to help you Sail the Servers of the Digital Ocean


You'll need a Digital Ocean Account before getting started (Signup here), then you'll need to create a New Droplet. Make sure to select Ubuntu Server:

Installation

SSH into your server and run the following command:

curl -sL https://github.com/thedevdojo/larasail/archive/master.tar.gz | tar xz && source larasail-master/install

You can make sure it's installed by running

larasail -h

Setup Your Laravel Server

larasail setup

The default configuration will install Nginx, PHP7.2, and MySQL 5.7. If you wish to use PHP7.1, you can include the argument php71 like so:

larasail setup php71

Creating a New Site

You can now Clone a Repo or Create a New Laravel app within the /var/www folder:

cd /var/www && laravel new mywebsite

Then, you'll need to setup a new Nginx Host by running:

larasail host mywebsite.com /var/www/mywebsite

larasail host accepts 2 parameters:

  1. Your website domain (website.com)
  2. The location of the files for your site (/var/www/website/public)

Finally, point your Domain to the IP address of your new server... And Wallah, you're ready to rock 🤘 with your new Laravel website.

Passwords

When installing and setting up Larasail there are 2 passwords that are randomly generated.

  1. The password for the new larasail user created on the server.
  2. The default MySQL password

To get the larasail user password you can type in the following command:

larasail pass

And the password for the larasail user will be displayed. Next, to get the default MySQL root password you can type the following command:

larasail mysqlpass

And the MySQL root password will be displayed.

Switching to Larasail user

When you SSH into your server you may want to Switch Users back to the larasail user, You can do so with the following command:

su - larasail

Make sure to star this repo and watch this repo for future updates. Thanks for checking out Larasail ⛵