So, I have tried 4 different ways of doing this, none of them worked.
There's a 3rd party server that I can create and delete files on via Filezilla. This was for testing purposes however.
There's a script on my Laravel application that'll run once a day, create a few XML files and those need to automagically transfer to that same server.
When I create an ftp filesystem I get the error "ftp_rawlist(): php_connect_nonb() failed: Operation now in progress (115)"
after a timeout.
When I try PHP's ftp_put or ftp_fput I get the error "ftp_put(): php_connect_nonb() failed: Operation now in progress (115)"
(or ftp_fput, same error).
When I try PHP's fwrite with the ftp as a destination I get the error "failed to open stream: operation failed". This also fails in the browser.
I have made sure credentials are correct. I've copy/pasted them from the working Filezilla connection details.
Filesystem code:
'ftp' => [
'driver' => 'ftp',
'host' => env('FTP_HOST'),
'username' => env('FTP_USERNAME'),
'password' => env('FTP_PASSWORD'),
'root' => '/Production',
'ssl' => true,
'ignorePassiveAddress' => true,
],
I know about the server behind NAT problem, but it won't accept my changes to use original address in filesystems. I've cleared cache, and config and fed the hamsters, but nothing changes.
I'm honestly at the end of my knowledge right now. And asking the 3rd party to change their configuration/settings isn't an option. This server is one of many and they're all exactly the same, but different clients. They might help me by providing the logs on their end, but that's about it.
The only other that I see which could be a difference is that I'm running this code from command line (ie, as if it's run via cron). Not sure if that causes problems with connecting and creating files on a remote server. I'm not that experienced with writing Laravel commands.
Any help would be greatly appreciated.
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire