Environment: Ubuntu Server - un-tared TAR file and set up directly on host OS
What is the recommended way to get InvoiceNinja running on a self-hosted system in such a way that future upgrades are not a complete disaster? Every time I try to upgrade everything goes horribly wrong. I saw there’s a new version but Force Update ends in an Error 500 followed by IN no longer working. I tried untar-ing the new tar file over all the old code files but that also failed spectacularly.
The built-in updater works reliably however it can require a large amount of RAM (ie. 2GB). Manually copying the tar should work, are there details about the 500 error in /storage/logs?
This was developed by a community member, you may find it helpful.
Greetings! Thanks for the response. I was able to find the log file, pasted below. Also, when the site loads without having an existing user logged in, it presents a popup saying that I should refresh the application.
It looks like a config issue with your server, here’s what ChatGPT suggest in case it’s helpful.
The Laravel error “could not find driver” typically means the required PHP database extension (like pdo_mysql or pdo_pgsql) is not installed or enabled on your server.
Fix It Step-by-Step
1. Check your database connection in .env
Make sure your .env is configured correctly, e.g.:
Thanks for your help. I was able to fix Ubuntu Server. It had a package dependency problem. I did sudo apt remove php8.3-common, then did php apt install php8.3-common. That allowed `sudo apt get-update’ and ‘sudo apt upgrade’ to work again. Although, InvoiceNinja appears to be using PHP 8.2.x.
I then did /usr/share/nginx/invoiceninja and php artisan migrate. Its result is INFO Nothing to migrate.
Then I went into the InvoiceNinja GUI and performed the Force Update. It now shows Version 5.12.0-C174. It appears to be running the latest same version listed on GitHub.
There is a remaining oddity however:
Health Check → System health: PDF: Invoice Ninja Hosted PDF: shows the error [2025-06-07 21:02:27] production.ERROR: Call to undefined method Illuminate\Console\View\Components\Task::runTimeForHumans() {"userId":1,"exception":"[object] (Error(code: 0): Call to undefined method Illuminate\\Console\\View\\Components\\Task::runTimeForHumans() at /usr/share/nginx/invoiceninja/vendor/laravel/framework/src/Illuminate/Console/View/Components/Task.php:45).
I did have a problem in the past where PDF invoices could not be generated but that was resolved by some cosmic event that defies explanation.