I am trying to install and configur the invoice ninja on my own domain on a shared host server with cpanel nginx and csf. It is not installed softaculous on this server. I read the guide on docs…
But nothing… (Realy, I feel stupid )
Is there any guide how to set up and what scripts must be on server ?
I’ll appreciate if someone can transfer his knowledge to me.
Softaculous is $12 per year, I would not run a server without Softaculous, we would (and may) switch from cpanel to another panel, however, whatever panel we use in cpanel’s place will have Softaculous.
I was able to do this just today. It took me a while, as I’ve never used Laravel before (I believe that Invoice Ninja is built on top of a framework called Laravel). The core problem you’re having is that Laravel (and Apache for that matter) expect your web root to be /public. Cpanel has it’s web root as /public_html.
I didn’t want to mess with the document root, although that’s likely the best answer here. Instead I did this:
My cpanel account was invoice. This made my web root /invoice/public_html
I uploaded the /ninja folder into the /invoice folder.
I moved everything that was in the /invoice/public folder to the /invoice/public_html folder
Edit the /invoice/public_html/.htaccess file and uncomment the RewriteBase
Finally, I followed the guidance here: https://stackoverflow.com/questions/30198669/how-to-change-public-folder-to-public-html-in-laravel-5
The only option that worked for me was the first answer - to add the following to the /invoice/public_html/index.php file:
// set the public path to this directory
$app->bind('path.public', function() {
return __DIR__;
});
I would note that we’re modifying Invoice Ninja files, so this would likely be overwritten when we upgrade. It’s not the best plan, but it should let you install on cpanel, probably even on shared hosting.