You are on page 1of 12

Smooth Capital

TECHNICAL
DOCUMENTATION
Oluwatobi Odekunle,

Lead Developer.
Bagisto Installation on MAC

Description: Installation of Bagisto on MAC

Written By: Oluwatobi Odekunle (Lead Developer)

Contact Information: ✉️ooluwatobialao@gmail.com 📞 08110951215

Last Updated: February, 2021

Overview:

Summary:

How to install Laravel Bagisto eCommerce solution MAC successfully.

Purpose:

To have Laravel Bagisto eCommerce solution installed locally on MAC.

Step 1: Download/Update Brew

Homebrew is a free and open-source software package management system that


simplifies the installation of software on Apple's macOS operating system and Linux.

Brew Download: Paste that in a macOS Terminal or Linux shell prompt.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Brew Update: Paste that in a macOS Terminal or Linux shell prompt.

brew update

Step 2: Install PHP using Brew

PHP is a general-purpose scripting language especially suited to web development.


Install PHP: Paste that in a macOS Terminal or Linux shell prompt.

brew install php@7.4

Step 3: Install NODEJS/NPM using Brew

Node.js is an open-source, cross-platform, back-end JavaScript runtime environment


that runs on the Chrome V8 engine and executes JavaScript code outside a web
browser.

NPM is a package manager for the JavaScript programming language.

Install NodeJS/NPM: Paste that in a macOS Terminal or Linux shell prompt.

brew install node

Step 4: Install Composer using Brew

Composer is an application-level package manager for the PHP programming language


that provides a standard format for managing dependencies of PHP software and
required libraries.

Install Composer:

Install Composer by going to the link: https://getcomposer.org/download/

Change the composer's path to default system path:

mv composer.phar /usr/local/bin/composer

Step 5: Install MySQL

MySQL is an open-source relational database management system. Its name is a


combination of "My", the name of co-founder Michael Widenius's daughter, and "SQL",
the abbreviation for Structured Query Language.
Install MySQL: Paste that in a macOS Terminal or Linux shell prompt.

brew install mysql@5.7.24

Step 6: Install Laravel Valet

Install Laravel Valet Dependency: Paste that in a macOS Terminal or Linux shell
prompt.

composer global require laravel/valet

Step 7: Install Valet

Valet is a Laravel development environment for macOS minimalists. Laravel Valet


configures your Mac to always run Nginx in the background when your machine starts.
Then, using DnsMasq, Valet proxies all requests on the *. test domain to point to sites
installed on your local machine.

Install Valet on your macOs: Paste that in a macOS Terminal or Linux shell prompt.

valet install

Step 8: Configure your TLD

A top-level domain is one of the domains at the highest level in the hierarchical Domain
Name System of the Internet. The top-level domain names are installed in the root zone
of the name space.

Paste that in a macOS Terminal or Linux shell prompt.

valet domain app/test

Step 10: Valet Park

The park command will register your current directory as a path that Valet should
search for your sites.
Paste that in a macOS Terminal or Linux shell prompt.

valet park

Step 11: Download bagisto using Composer

Bagisto is an eCommerce ecosystem designed for all to build and scale your business.
It's a free and open source eCommerce framework which offers you a wide range of
functionality and lets you have total control of your store.

Download bagisto in a folder named sites(create if not there) inside home: Paste
that in a macOS Terminal or Linux shell prompt.

composer create-project bagisto/bagisto bagisto

Your new site should be accessible on http://bagisto.app

Step 12: Bagisto GUI Installation

Go to your browser and access your site: http://bagisto.app. Bagisto installer will pop
up in the next step where it will check for the minimum configuration as mentioned in the
prerequisites. If everything is alright, click the Continue button.

In the next step, you need to fill the environment variables, at last Save and Continue.
App Name

Here you need to provide the name for your application or your eCommerce store.

App URL

Here you need to provide the application URL, after hitting which front-end of your store
appears.

Database Connection

Choose the Database Connection that you will be using in the Database Connection.

Database Port

Here you need to provide the port number of the database that you will use. Most times
it is always 3306 as the default value.

Database Host

Provide database hostname to connect your site to your database. Default value:
127.0.0.1 but you can choose any host you want.

Database Name

Provide the name for the database that you have created for the store. You need to
have a database created already. Just provide the name.

Username

The database server username will be provided here.

Password
Here you also need to provide the password for the database server.

Next, you will need to click on the Migrate and Seed button to perform successful
migration and also for loading test data in the tables.
Once the Migration and Seeder operation is completed, click on the Continue button.
At last, you will be needed to provide Admin details for your eCommerce store.
Click on Finish after the installation has been over and you will be redirected to the Sign
In Page, where you will provide the admin details to check the admin panel.
Step 13: Alternative to Step 12

Change directory for other commands below:

cd inside the folder bagisto

Note: Put the details for MySQL database and APP in .env file:

APP_URL

DB_CONNECTION

DB_HOST

DB_PORT

DB_DATABASE
DB_USERNAME

DB_PASSWORD

Run Migration To Get All Tables that Bagisto Requires:

php artisan migrate

Run this If you need demo data:

php artisan db:seed

Run this to publish all assets from config files to assets:

php artisan vendor:publish

-> Press 0 and then press enter to publish all assets and configurations.

Make the symlink for storage/public inside public directory:

php artisan storage:link

CONCLUSION

Kindly let me know if you have any issue during the installation. Thanks.

You might also like