Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

mikaeledstrom's avatar

Deploy when in maintenance mode

Hello,

Is it considered best practice to deploy new code with Laravel when the app/site is "down" in maintenance mode?

0 likes
2 replies
Snapey's avatar

depends how long it takes, but that IS what its there for. Updating your code or running database queries is considered maintenance

mikaeledstrom's avatar

The background is that we will do a migration to a new database server. Instead of changing a lot of .env database variables in .env file, I could do new db connections in Laravel and prepare all the .env variables and deploy the new code that uses the new connections instead.

Please or to participate in this conversation.