fms-chat is an application for chatting between registered users.
This project is build with docker, then you need to create an docker environment an use this docker-compose.yml.
To run this project, you will need to add the following environment variables to your .env file
NOTE: this is the service's name in docker-compose
change this for production!
change this for production!
DB_ROOT_PASSWORD=Passw0rd_t0_r00t change this for production!
APP_ENV=local or APP_ENV=production
APP_URL=http://localhost or APP_URL=http://your_production_url.xxx
Additional mailpit configuration required.
1.- Create the project automatically using the laravel build: curl -s "https://laravel.build/your_project_name?with=mariadb,mailpit" | bash
2.- Then, the frontend part must be prepared with breeze-inertia: composer require laravel/breeze –dev
3.- Then we must install laravel breeze php artisan breeze:install
- Answer “Inertia-Vue” to the question of which front end you want to install.
- Answer “Typescript” to the question for additional installation.
4.- Then, launch the ./vendor/bin/sail up -d
to build the project, generating the containers to work with.
5.- At this point we have the skeleton of the project. We must verify if we have connection with the database:
- Try to connect using phpmyadmin, in the configured url: http://localhost:8080
- The user must be the value of DB_USERNAME defined in .env, and the password must be DB_PASSWORD value.
- Remember that the DB_HOST must be the name of the service defined in docker-compose.yml, in this case fms-chat-mariadb. If the database manager asks for the host, you must enter this value.
6.- Enter inside the php container with: docker container exec -it fms-chat-php /bin/bash
7.- Inside the container, run the breeze migration installation to install the user tables in the database: php artisan migrate
8 - Inside the container, install the project with npm install
(usually it will say that everything or almost everything is up to date)
9.- And finally, inside the container, to run the application npm run dev
If a port conflict occurs, the conflicting ports should preferably be changed in the .env file (APP_PORT, VITE_PORT, PHPMYADMIN_PORT)