DAVE is the Daily Attendance & Validation Engine, a Laravel application to allow employees to track their working hours.
Clone the project
git clone https://github.com/angus-websites/ONSDave24.git
Go to the project directory
cd ONSDave24
Setup Laravel Sail
NOTE: Ensure you have Docker installed
docker run --rm \
-u "$(id -u):$(id -g)" \
-v $(pwd):/var/www/html \
-w /var/www/html \
laravelsail/php81-composer:latest \
composer install --ignore-platform-reqs
Generate a .env file
cp .env.example .env
Run Laravel Sail (Development server)
TIP: Add ./vendor/bin/sail
as an alias to sail
on your machine to make this command easier to run
./vendor/bin/sail up
Open a new Terminal tab in the same project root folder
Generate an app encryption key
./vendor/bin/sail php artisan key:generate
Migrate the database
./vendor/bin/sail php artisan migrate
Seed the database
./vendor/bin/sail php artisan db:seed
Install NPM dependencies
./vendor/bin/sail npm i
Run Vite
./vendor/bin/sail npm run dev
Visit Localhost
New version of ONSDave written in Laravel 11
- Go to
Settings
>PHP
>Test Frameworks
- Click on
+
and selectPHPUnit by Remote Interpreter
- Click on
...
next to "CLI Interpreter" - Click on
+
and selectFrom Docker, Vagrant, VM, WSL, Remote...
- Select
Docker Compose
- Select
Service
aslaravel.test
- Click Apply and OK
- In the
PHHPUnit Library
section ensure the "Path to script" is set to/var/www/html/vendor/autoload.php
- Click Apply and OK
- Ensure the
SAIL_XDEBUG_MODE=develop,debug,coverage
is set in the.env
file