This morning I renewed the SSL cert for invoice.[my_domain].us, and updated my nginx proxy VM (which is separate from my ininja VM) with the renewed cert. After I was done the https lock logo turned from red to green and everything seemed to work perfectly.
However, after saving a new invoice I tried to send it via email, and I ended up with this error: Unable to open file for reading [https://invoice.[my_domain].us/logo/bFiEQM.png]
The file that it referenced was my company logo file.
I noticed in this thread that the same error was received for an incorrect URL in the SSL cert.
I’m sure the URL is correct. I’ve delved through every log that I know about in both VMs and can’t find any related info. The owner/permissions on the cert/key files are identical to my other functioning sites. I don’t know what else to do. Can you please point me in the right direction?
I’m at a complete loss here. Why would the logo file be accessible from a web browser, but not when ininja tries to access it to put it in a PDF file and email it?
I added this to the end of my .env file and rebooted:
TRUSTED_PROXIES='10.1.1.0/24'
No joy. I also successfully accessed the logo file directly using the LAN IP of the VM, rather than my domain name. I also attempted to email an invoice using the same method in order to eliminate the proxy as a problem. It didn’t work. It appears that the proxy is completely transparent.
After doing all of this I scoured the logs again for any mention of the attempt to send an email. Not a word.
I’m in the same boat here. I just created a new SSL cert today, and I have my setup going through nginx as a reverse proxy. InvoiceNinja is setup to run behind apache2. I tried adding the IP to the allowed proxies paramter, no fix, I tried the IP range, no fix.
Now, the curious thing is that I can also remote into the local network and connect to the InvoiceNinja host directly, as in not going through the reverse proxy, and I still get the error.
For no I’m just going to take off my logo, but I really do need to get this fixed, and I’m not sure what’s going on. Permissions for the web files also looks correct.
I’m thinking it should be safe to just add that code change directly to the relevant php files, which I’m comfortable doing. But, is it a bad idea for a reason I don’t know?