MgHtinLynn / laravel-web-test

Web Developer Test

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Laravel-Web-Test

Web Test System with Laravel 8 + VueJS + API

Setup

Docker Desktop

Host Setup with https certificate

https://laravel.com/docs/8.x/valet

composer global require laravel/valet
valet install

Local Dev Setup

  • clone repo from Github
git clone https://github.com/MgHtinLynn/laravel-web-test.git
cd laravel-web-test

Link valet certificate with nginx proxy

ln -s /Users/htinlynn/.config/valet/Certificates {dir of repo clone}/data/
ln -s /Users/htinlynn/.config/valet/Certificates /Users/htinlynn/Code/htinlynn/laravel-web-test/data/

Link Valet With Https URL

valet secure {host-name}

For Example

valet secure web-test

That will generate https certificate for your repo

We have to disable nginx port 80 in PC or Laptop

valet stop

For Server Up

docker-compose up -d

For Sever Down

docker-compose down

!!BOOM!!

You can call your host name to web-browser

In my mac https://web-test.test/

if different dir, need to update docker-compose file.

For Migration

cp .env.example .env
docker exec -it app bash
php artisan migrate

For API Earthquakes API Link .env file

API_URL = "https://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/all_hour.geojson"

The First Task -

The Second Task For API Testing, There is a file . You can import in your postman.

  • Products.postman_collection.json
  • Get Products
  • Store Product

Enjoy your setup.

If any problem , open the issue.

Htin Lynn, htinlin01@gmail.com, 09785360975

About

Web Developer Test

License:MIT License


Languages

Language:PHP 89.5%Language:Blade 5.3%Language:Vue 2.6%Language:Dockerfile 1.7%Language:Shell 0.9%