Skip to content

Deployment Laravel & Windows (XAMPP)

Piethein Strengholt edited this page Apr 7, 2021 · 1 revision

How to install meet-Alex with Xampp (Windows)

Install Xampp

First of all, we need Xampp. Download this from the official page:

A direct link is here: https://www.apachefriends.org/xampp-files/5.6.30/xampp-win32-5.6.30-0-VC11-installer.exe

Install Composer

Next step is to download and install Composer https://getcomposer.org/download/ Leave the proxy option blank, when asked

Install Github for Windows

Install GitHub for Windows, download from https://desktop.github.com/

Deployment

Clone repository

Using GitHub for Windows, clone the meet-Alex repository, save the repository in C:\xampp\htdocs\

Edit httpd-vhosts.conf

Edit the httpd-vhosts.conf file, that is located in C:\xampp\apache\conf\extra\httpd-vhosts.conf and add following lines at the end of the file:

# VirtualHost for meet-alex.dev

<VirtualHost meet-alex.dev:80>
  DocumentRoot "C:\xampp\htdocs\meet-Alex\public"
  ServerAdmin meet-alex.dev
  <Directory "C:\xampp\htdocs\meet-Alex">
        Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted
  </Directory>
</VirtualHost>

Add virtual host

Open C:\Windows\System32\drivers\etc\hosts Add a line with:

127.0.0.1 meet-alex.dev

Download dependencies

Next step is to download all dependencies using composer. Go to the C:\xampp\htdocs\meet-Alex directory and type 'composer install', see below:

C:\xampp\htdocs\meet-Alex>composer install

Deploy config file

C:\xampp\htdocs\meet-Alex>copy .env.example .env

Create the directory "C:\xampp\mysql\lib\plugin" , see http://stackoverflow.com/questions/42033926/phpmyadmin-mysql-error-1018-xampp

Create database and user

Open http://localhost/phpmyadmin/ Use the new button on the right to create a new database, name it meet-alex

Click on the newly created database, select Privileges, Click on Add user account. Make sure it is set to 'meet-alex'@'localhost' and not to 'meet-alex'@'%'

Update config file

Edit the C:\xampp\htdocs\meet-Alex\.env file;

Change to:

DB_DATABASE=meet-alex
DB_USERNAME=meet-alex
DB_PASSWORD=password

Also change the APP_URL and SESSION_DOMAIN. Set both to meet-alex.dev

APP_URL=http://meet-alex.dev
SESSION_DOMAIN=meet-alex.dev

Add missing folders

Create the following folders, if missing:

mkdir bootstrap\cache
mkdir storage\framework
mkdir storage\framework\sessions
mkdir storage\framework\views
mkdir storage\framework\cache

Create unique key

Run: php artisan key:generate

Deploy database scripts

Run: php artisan migrate

Validate results

Open your browser and go to http://meet-alex.dev