I tried updating to latest this morning, and half way expected something to go wrong because I recently spun up a blank vm of this version and immediately got errors - I was correct.
I will roll back my production vm but leaving this information here so perhaps it can be addressed before next update.
The error occurred when I tried to archive some invoiced tasks. Gave me “500 internal server error”.
Linking the post about the blank vm error on first setup for reference.
Apparently I can not roll back because my snapshots were not firing as of a few days ago. So this is now a lot more time sensitive as I can not invoice or create new work tasks. Any ideas would be much welcome.
If I have to spin up a new server and transfer the data into it, I can do that.
just unzip the .16 over the current, or do I need to rename the current/copy out storage dir and /env file, then unzip and copy those two items back?
I’ve never downgraded before, so I need to make sure I am doing it correctly.
thanks
Earlier, I though it had not, but that was because I unzipped into the parent directory, which, of course, produced odd results.
Rolled my vm back, correctly installed 5.12.16 over 5.12.17 and I am now able to work again.
If you’re planning to roll back your self-hosted Invoice Ninja installation, it’s best to avoid overwriting the current setup directly. Instead, here’s a clean and reliable method I recommend:
Safe Rollback Method
Create a new directory for the version you want to install.
Copy over your public/storage folder and your .env file from the current installation.
Rename the old install directory to something like invoice-ninja-backup to keep it as a fallback.
Rename the new install directory to match your production path.
Run php artisan optimize in the new directory to finalize the setup.
This approach lets you cleanly install any version while preserving your configuration and uploaded files. It also gives you a quick way to revert if something goes wrong.
Additional Best Practices
Backup your database first
Always a good precaution, even though Invoice Ninja’s database migrations are generally backward-compatible. In most cases, rolling back won’t cause schema issues—but having a backup is still wise.
Check for breaking changes
Review the changelog of the version you’re rolling back to. Some features or settings may have changed or been deprecated.
Verify file permissions
After copying and renaming directories, ensure correct permissions and ownership—especially for storage and bootstrap/cache.
Clear all caches
Run these commands to avoid stale config or view data:
Note: If you’re using the compiled ZIP release from GitHub, all dependencies are already included, so there’s no need to run composer install.
This method has worked reliably for me many times, and I even use a script to automate it. It’s safer than relying on auto-updaters or server-level backups, which can be hit-or-miss (especially with cPanel).