@JVAHLDICK - I am running this site on Valet.
But I think the issue is related to the wrong cert being referenced.
When I run dump( openssl_get_cert_locations() ); in my routes/web.php file, I get this:
array:8 [
"default_cert_file" => "/usr/local/etc/openssl/cert.pem"
"default_cert_file_env" => "SSL_CERT_FILE"
"default_cert_dir" => "/usr/local/etc/openssl/certs"
"default_cert_dir_env" => "SSL_CERT_DIR"
"default_private_dir" => "/usr/local/etc/openssl/private"
"default_default_cert_area" => "/usr/local/etc/openssl"
"ini_cafile" => ""
"ini_capath" => ""
]
However, when I run that same command inside the handle() method of my Job, I get this:
array:8 [
"default_cert_file" => "/Applications/MAMP/Library/OpenSSL/cert.pem"
"default_cert_file_env" => "SSL_CERT_FILE"
"default_cert_dir" => "/Applications/MAMP/Library/OpenSSL/certs"
"default_cert_dir_env" => "SSL_CERT_DIR"
"default_private_dir" => "/Applications/MAMP/Library/OpenSSL/private"
"default_default_cert_area" => "/Applications/MAMP/Library/OpenSSL"
"ini_cafile" => ""
"ini_capath" => ""
]
Obviously it's picking up the cert in my MAMP app (which isn't currently running).
For now, I have implemented a workaround which checks the "ENV" and verifies only if not in "local".
$response = $client->get( "files/{$file_id}", [
'verify' => ( env( 'APP_ENV' ) === 'local' ) ? false : true,
'headers' => [
"Authorization" => "Bearer {$token}",
"Accept-Encoding" => "application/json",
"Content-Type" => "application/json",
"cache-control" => "no-cache",
],
] );
Do you think this cert issue will go away once both the client and API server are running on Forge?