# Web Installer Guide

## Installer URL

After uploading the Laravel ERP to hosting, open:

```text
https://your-erp-domain.com/install
```

Example:

```text
https://erp.mboutiquebd.com/install
```

## What The Installer Does

The installer will:

1. Check important server requirements.
2. Ask for application name and URL.
3. Ask for MySQL/MariaDB database details.
4. Test the database connection.
5. Write the `.env` file.
6. Run Laravel database migrations.
7. Create the first admin user.
8. Create `storage/app/installed.lock`.

After the lock file is created, the installer will not run again.

## Important Data Safety Rule

Use a new empty database for Laravel ERP.

Do not enter your live WordPress database as the Laravel target database.

Your existing WordPress/WooCommerce/plugin data should be imported later through a controlled migration tool after backups are taken and totals are verified.

## Required Hosting Settings

Your Laravel hosting should support:

- PHP 8.2 or newer
- MySQL/MariaDB
- PDO MySQL extension
- OpenSSL extension
- Mbstring extension
- Fileinfo extension
- Writable `storage` folder
- Writable `bootstrap/cache` folder

## Folder Setup

For Laravel hosting, the web root should point to:

```text
public
```

Do not point the domain to the Laravel project root.

Correct:

```text
mboutique-erp-laravel/public
```

Incorrect:

```text
mboutique-erp-laravel
```

## Installer Lock

After installation, this file is created:

```text
storage/app/installed.lock
```

Keep this file in place on production.

Only remove it if you intentionally need to re-run installation on a fresh staging database.

## Next Step After Installer

After installation, build and run the migration/import process:

1. Back up WordPress database and files.
2. Export current plugin tables.
3. Import into Laravel staging database.
4. Compare stock, purchase, receivable, supplier due, bank/cash, courier, and journal totals.
5. Connect WooCommerce API only after totals match.
