Knowledgebase

Configuring the Environment on Your Hosting Print

  • phplaravel, caching, cpanel, database, performance, errors, troubleshooting, guide
  • 0

Settings in production.

WHAT TO CREATE

The environment file, on the server, from your example.

WHAT TO SET

The environment name as production Debug mode off The application address Database credentials, with cPanel prefixes Mail settings The application key

WHAT TO DO ABOUT THE KEY

Generate one on the server, or copy the one you use, consistently.

WHY CONSISTENCY MATTERS

Changing it invalidates existing sessions and anything encrypted with it.

WHAT TO VERIFY

That the file is not publicly reachable

WHAT TO SET FOR LOGGING

A level appropriate to production, and a channel that rotates.

WHY ROTATION

A single growing log file eventually fills your disk.

WHAT TO CACHE AFTER CONFIGURING

Configuration and routes, for performance.

WHAT THAT MEANS

Any later change requires rebuilding those caches.

WHAT TO NEVER DO

Leave debug mode on.

WHAT IT EXPOSES

Configuration values, including credentials, in error pages.


Was this answer helpful?
Back

Are you happy with your experience? Leave us a review on Trustpilot.


Trustpilot