- Issue created by @ciesinsg
- 🇳🇱Netherlands roderik Amsterdam,NL / Budapest,HU
That looks like something in your webserver config.
In the script that you execute by opening it in your webbrowser, you can print
ini_get('open_basedir')
. If that is something that is more specific than/var/www/websites/cabstg
, that's your issue.And if the value is equal to your webroot (whatever it is... e.g.
/var/www/websites/cabstg/public
)... that would be bad. Because it means you would be forced to put your private key in your webroot. And I hope your web server team is able/willing to change that setting. - 🇨🇦Canada ciesinsg
@roderik Thanks for the suggestion. I modified the script to include
echo "open_basedir: " . ini_get('open_basedir') . "\n";
But when I run this from PHP cli this just outputs "open_basedir: " and nothing afterwards as if there is no basedir set. I am not sure exactly what this means as this seems to be a different outcome than you mentioned. Does this mean that there's no basedir set, or is this variable hidden to me?
- 🇳🇱Netherlands roderik Amsterdam,NL / Budapest,HU
There's no basedir set.
Then I have no clue about the difference between CLI PHP and your webserver PHP (with only the latter not being able to find the files, as you mentioned in the initial reply)
- 🇳🇱Netherlands roderik Amsterdam,NL / Budapest,HU
I'm too quick answering, sorry. This should not be run from PHP cli, that is expected to contain nothing.
When run through the webserver (i.e. viewed as a webpage, i.e. put somewhere in the webroot) it is expected to contain a value. (Make sure to not output your private key, in that script)
- 🇨🇦Canada ciesinsg
Hi Roderik, thanks for all your help with this. We were able to discover the issue so I wanted to include this here in case it helps anyone.
The issue was that the transfer instance was setup with the wrong directory name. Even though the directory I was working in was cabstg, the actual server was set to cab so the URLs I made simply didn't exist on the server. After the transfer instance and server were made to match, and I corrected the absolute paths, it is working as intended.
- Status changed to Closed: works as designed
12 months ago 2:33pm 11 January 2024