https://github.com/maxgfr/ticke
Ticke Application
https://github.com/maxgfr/ticke
backend backoffice laravel ticket ticket-generator
Last synced: 3 months ago
JSON representation
Ticke Application
- Host: GitHub
- URL: https://github.com/maxgfr/ticke
- Owner: maxgfr
- Created: 2018-04-11T07:51:18.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2024-02-29T20:20:37.000Z (about 1 year ago)
- Last Synced: 2024-12-25T14:42:50.085Z (4 months ago)
- Topics: backend, backoffice, laravel, ticket, ticket-generator
- Language: PHP
- Homepage:
- Size: 1.98 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ticke
## Initialize
### 1) In .env of laravel app, add :
```
DB_HOST=mysqlREDIS_HOST=redis
QUEUE_HOST=beanstalkd
```### 2) In the app directory:
```
git clone https://github.com/Laradock/laradock.git
cd laradock
cp env-example .env
```### 3) In laradock/, open .env and add :
```
APP_CODE_PATH_HOST=../
```### 4) Launch :
```
docker-compose up -d nginx mysql phpmyadmin redis workspace
```### Commands
To connect to container :
```
docker-compose exec workspace bash
docker-compose exec workspace mysql
```### Problems :
#### 1° In laradock/
Restart containers :
```
docker-compose down
docker-compose up -d nginx mysql phpmyadmin redis workspace
```Connect to a container :
```
docker-compose exec workspace bash
composer install
php artisan key:generate
php artisan cache:clear
php artisan config:cache
php artisan migrate
```Switch from mysql to mariadb :
To use with MariaDB, in laradock open .env and set PMA_DB_ENGINE=mysql to PMA_DB_ENGINE=mariadb
```
docker-compose down
docker-compose up -d nginx mariadb phpmyadmin redis workspace
```
Then, in .env of the app :
```
DB_HOST=mariadb
DB_PORT=3306
DB_DATABASE=default
DB_USERNAME=root
DB_PASSWORD=root
```### 2° In app directory :
```
php artisan cache:clear
php artisan config:cache
``````
chmod -R 777 storage bootstrap/cache
```### 3° JWT - Laravel 5.6 :
https://github.com/tymondesigns/jwt-auth/issues/1038
## Test API
### Register
```shell
curl -X POST http://localhost:8000/api/register \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{"name": "Doe", "firstname": "John", "mobile": "0621425347", "email": "[email protected]", "password": "maxmaxmax", "password-confirm": "maxmaxmax"}'
```
### Login```shell
curl -X POST http://localhost:8000/api/login \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{"email": "[email protected]", "password": "maxmaxmax"}'
```