Use this file to discover all available pages before exploring further.
Corpen reads its configuration exclusively from the .env file in the project root. This file is never committed to version control. Start by copying the example template and then editing each group of variables for your environment:
cp .env.example .envphp artisan key:generate
The sections below document every variable group, their accepted values, and the Corpen behaviour they control.
For local development, consider using Laravel Sail (laravel/sail is included as a dev dependency). Sail provides a pre-configured Docker environment with PHP, MySQL, and Redis. Run ./vendor/bin/sail up and set DB_HOST=mysql to match the Sail MySQL service name. All other variables described in this guide apply equally in a Sail environment.
A base64-encoded 32-character random string. Generated automatically by php artisan key:generate. All encrypted session data and cookies depend on this value — rotating it will invalidate all active sessions.
Setting APP_DEBUG=true in production exposes stack traces, environment variables, and database queries in browser error pages. Always set it to false before going live.
The database must be created manually before running php artisan migrate. Corpen ships over 60 migrations covering all modules — insurance, credits, archive, reservations, workflows, and more.
# Create the database before migratingmysql -u root -p -e "CREATE DATABASE corpen CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;"php artisan migrate
Corpen uses queues for Excel exports (via maatwebsite/excel) and PDF generation (via barryvdh/laravel-dompdf). In production, use database (requires a running queue worker) or redis for better throughput. sync is only appropriate for local development.
For Redis-backed cache and sessions, add the following to .env:
The public disk maps storage/app/public to public/storage via the symlink created by php artisan storage:link. This disk is used for uploaded documents, insurance policy attachments, and employee photos.
Corpen includes google/cloud-storage (^1.48) as a Composer dependency. Google Cloud Storage can be used as an alternative object store for document uploads and employee file management.
The google/cloud-storage SDK authenticates via a service account JSON key file. Download the key from the GCP Console (IAM & Admin → Service Accounts → Keys), place it on your server outside the web root (e.g. /etc/corpen/gcs-credentials.json), and set GOOGLE_APPLICATION_CREDENTIALS to that absolute path. Never commit the JSON file to version control.
Variable
Description
GOOGLE_CLOUD_PROJECT_ID
Your GCP project ID, found in the GCP Console dashboard.
GOOGLE_CLOUD_STORAGE_BUCKET
Name of the GCS bucket to use for file storage.
GOOGLE_APPLICATION_CREDENTIALS
Absolute path to the service account JSON key file on the server.
Corpen uses Laravel’s standard mail stack. The default mailer is log, which writes emails to storage/logs/laravel.log — safe for development, but must be changed for production.
Variable
Default
Description
MAIL_MAILER
log
Transport driver: smtp, sendmail, ses, resend, postmark, log, array.
MAIL_HOST
127.0.0.1
SMTP server hostname.
MAIL_PORT
2525
SMTP port. Common values: 587 (STARTTLS), 465 (SSL), 25.
MAIL_USERNAME
(empty)
SMTP authentication username.
MAIL_PASSWORD
(empty)
SMTP authentication password.
MAIL_ENCRYPTION
tls
tls, ssl, or null.
MAIL_FROM_ADDRESS
(empty)
Sender email address for all outgoing mail.
MAIL_FROM_NAME
${APP_NAME}
Sender display name. Defaults to the value of APP_NAME.
Corpen includes google/apiclient (2.15) as a Composer dependency, which is used for Google Drive integration and Sheets data sync. This SDK also uses GOOGLE_APPLICATION_CREDENTIALS for server-to-server (service account) authentication.
Variable
Description
GOOGLE_APPLICATION_CREDENTIALS
Path to the service account JSON key file. Shared with the GCS configuration above.
For OAuth2 flows (user-delegated access), you would also configure a client ID and secret through the GCP Console OAuth Credentials screen. These are typically stored as custom .env variables matching your application’s OAuth redirect URIs.