georgestav / whadodo

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Laravel, React, Typescript, Sass, PHP, NGINX, MYSQL - Dockerised ready to set sails

Container & Deployment:

Docker Kubernetes

Served with:

Laravel MySQL PHP Nginx

Presented by:

React TypeScript SASS

Tooling:

NPM NodeJS

Laravel React project,

Using:

  • PHP @ 8.1 sha256:bdaaed87c00568472c469cb705d3abc52ea883ecb07dc4e491ae34230b4e9896
  • NGINX @ Latest-alpine sha256:8d4fc999c0199edf0fcae821651ba9463075f6a1100b6a37c7b95bfdc76bdb70
  • MYSQL @ latest sha256:0c0beeac7ca1937d60f54e1fb0c4a5c0b0ffee2aae37488fbc9f5ea301425551
  • Composer @ latest sha256:4895de8697c6eade19f3261eb88cb41d564f213d5956faf74a329adf0c6e59c8
  • Npm with NodeJS @ lts

Comes with:

  • React @ 18.1
  • Typescript @ 4.7
  • Sass @ 1.52
  • Bootstrap @ 5.1
  • Browsersync & axios

How to run the project

  1. Copy the mysql.env.example in the env folder to mysql.env and fill out the project details

  2. Install the vendor dependencies docker-compose run --rm composer install

  3. Copy the .env.example found in src to .env and fill out the project details making sure they match the mysql.env values.

  4. Generate a new app key by running docker-compose run --rm artisan key:generate

  5. Start the server and start developing docker-compose run npm i

  6. Start the server and start developing docker-compose up -d server

  7. Start Broswer Sync to view live changes docker-compose run --rm --service-ports npm run watch

Other commands

You can stop the server with docker-compose down All artisan commands with docker-compose run --rm artisan [your input] All composer commands with docker-compose run --rm composer [your input] All npm commands with docker-compose run --rm npm [your input]

Sidenote

If when migrating the tables is failing:

  1. Make sure your credentials are right in the .env file and retry
  2. Verify that in the .env file you are passing the name of the mysql container and not localhost or 127.0.0.1 and try again
  3. run docker-compose run --rm composer require doctrine/dbal to install a missing dependency

Kubernetes not implemented yet, will be once closer to deployment

About


Languages

Language:PHP 82.1%Language:TypeScript 15.0%Language:JavaScript 0.9%Language:Shell 0.7%Language:Dockerfile 0.5%Language:SCSS 0.4%Language:Blade 0.4%