SuperFullStack / symfony-vue-coreui

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Setup

First, make sure you are running the latest version of Docker and Docker Compose.

Windows is not supported, period.

On macOS, add those lines in your /etc/hosts file:

127.0.0.1   web.localhost
127.0.0.1   phpmyadmin.web.localhost

Clone the project, move to its root directory and run:

$ cp .env.template .env
$ make up

This command will start the stack and also run the following commands in the web service:

  • composer install: installs PHP dependencies
  • yarn install: installs frontend dependencies
  • php bin/console doctrine:migrations:migrate --no-interaction: runs the migration patches on the database

Once the web service is ready, you may now run bash inside it with:

$ make bash

Here you have to run the following commands:

$ yarn dev
# builds the frontend application...
$ php bin/console doctrine:fixtures:load --append
# adds fake data in the database...

Note: a watcher is also available with yarn watch.

Available commands

$ make up

Starts the stack.


$ make down

Stops the stack


$ make bash

Runs bash inside the web service.

Workflow before each push

Run the following command in the web service:

$ composer run csfix && composer run cscheck && composer run phpstan

Workflow for database tables generation

Go the web service:

$ make bash

Create your PHP entity:

$ php bin/console make:entity

Generate the migration script:

$ php bin/console doctrine:migrations:diff

Execute the migration script to generate your db:

$ php bin/console doctrine:migrations:migrate

About


Languages

Language:PHP 69.6%Language:Vue 20.6%Language:JavaScript 8.8%Language:Twig 0.4%Language:SCSS 0.4%Language:Shell 0.1%Language:Dockerfile 0.0%Language:Makefile 0.0%