Skip to content
IFRCGoPublic

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

3 watching

Forks

Latest commit

 

History

586 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Laravel-Vue-Bootstrap Project

WhatNow

WhatNow is a web application being migrated to Laravel 13 and Vue.js, designed to provide a disaster preparedness guide. This document includes steps to install and configure the project in your development environment.

The Laravel 13 dependency lock and runtime validation are still pending. See Laravel 13 migration for the current status, validation commands and release requirements.

Prerequisites

Ensure the following tools are installed on your system:

  • PHP (version 8.4; Laravel requires at least 8.3):
    php -v
  • Composer (dependency manager for PHP):
    composer --version
  • Node.js (version 22):
    node -v
  • npm (Node.js package manager):
    npm -v
  • MySQL (version 8.0 or higher):
    mysql --version

Project Installation

  1. Clone the Repository

    git clone https://github.com/YourUsername/WhatNow.git
    cd WhatNow
  2. Install PHP Dependencies

    composer install
  3. Install JavaScript Dependencies

    npm install
  4. Set Up Environment

    • Copy the .env example file and configure it as your environment file:
      cp .env.example .env
    • Generate an application key for Laravel:
      php artisan key:generate
  5. Database Configuration

    • Create a MySQL database named homestead.
    • Open the .env file and update your database credentials:
    DB_CONNECTION=mysql
    DB_HOST=127.0.0.1
    DB_PORT=3306
    DB_DATABASE=homestead
    DB_USERNAME=your_username
    DB_PASSWORD=your_password
    
  6. Run Database Migrations

    php artisan migrate

    Optional: If you would like to populate the database with initial sample data, you can run the database seeder command:

    php artisan db:seed
  7. Compile Frontend Assets

    • For development:
      npm run hot
    • For production:
      npm run production
  8. Start the Development Server

    php artisan serve

Development Commands

Command Description
php artisan serve Starts the local development server
npm run hot Compiles assets and hot-reloads changes
npm run production Compiles assets for production
php artisan migrate Runs database migrations
php artisan db:seed Seeds the database with sample data
php artisan make:model Creates a new Eloquent model
php artisan make:controller Creates a new controller

Documentation

API Endpoints Documentation

The API endpoints documentation can be found at the /endpoints route.

Troubleshooting

  1. Verify Dependencies: Ensure all dependencies are properly installed.
  2. Environment File: Check that the .env file is correctly set up.
  3. Dependency Conflicts: If issues arise, run composer update and npm install to resolve them.
  4. Database Connection: Verify that the database credentials in the .env file are correct.
  5. Migrations: If migrations fail, check the database connection and run php artisan migrate:status.
  6. Frontend Assets: If assets are not compiling, run npm run production or npm run hot to recompile them.
  7. Development Server: If the server fails to start, check the port and run php artisan serve again.

Testing

Run the PHPUnit 12 suite with PHP 8.4 after resolving the migration lockfile:

composer test

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

3 watching

Forks

Releases

Packages

Used by

Contributors

Languages