Perhaps something wrong with a firewall in production ?
Timeout with Guzzle!?
I have this code just to call an SMS service via Laravel Http:
$respone = Http::acceptJson()->post(
'https://www.XXXXX.com/gw/sendsms.php',
[
"userName" => config('sms.sms_user'),
"numbers" => $number,
"userSender" => config('sms.sms_user_sender'),
"apiKey" => config('sms.sms_api_key'),
"msg" => $msg
]
)->json();
This code works locally perfectly. but once I deploy this code on the server I got a timeout!
I'm using AWS EB PHP 8.1 running on 64bit Amazon Linux 2/3.4.0
When I SSH on the server and use CURL to the same URL, it takes like infinite time to return and no response back!
To make sure, I create another micro server on EC2 and use CURL to the same URL service here I got a response!
I have other services also I'm using HTTP Laravel for them and they are working just fine!
I do not what is the problem! everything in the app is working except this service!
Please or to participate in this conversation.