-
Notifications
You must be signed in to change notification settings - Fork 76
[EN] Local Installation
Lito edited this page Apr 4, 2024
·
3 revisions
-
Create the MySQL database.
-
Clone the repository.
git clone https://github.com/eusonlito/GPS-Tracker.git
- Copy the
.env.example
file as.env
and fill in the necessary variables.
cp .env.example .env
- Install composer dependencies (remember that we always use the PHP 8.2 binary).
./composer install --no-dev --optimize-autoloader --classmap-authoritative --ansi
- Generate the application key.
php artisan key:generate
- Regenerate the caches.
./composer artisan-cache
- Launch the initial migration.
php artisan migrate --path=database/migrations
- Launch the seeder.
php artisan db:seed --class=Database\\Seeders\\Database
- Fill Timezones GeoJSON.
php artisan timezone:geojson
- Configure the cron job for the user related to the project:
* * * * * cd /var/www/tracker.domain.com && install -d storage/logs/artisan/$(date +"\%Y/\%m/\%d") && /usr/bin/php artisan schedule:run >> storage/logs/artisan/$(date +"\%Y/\%m/\%d")/schedule-run.log 2>&1
- Create the main user.
php artisan user:create [email protected] --name=Admin --password=StrongPassword2 --enabled --admin
-
Configure the web server
DocumentRoot
to/var/www/project/public
. -
Profit!
Updating the platform can be done in a simple way with the ./composer deploy
command executed by the user who manages that project (usually www-data
).