Monday, March 14, 2022

[SOLVED] Laravel on Kubernetes - CronJob swift 550 5.7.1 Relaying denied

Issue

I've deployed a Laravel app on Kubernetes. Inside the app, mails are sent without any problems.

I wrote a Laravel command to send notifications, and deployed a Kubernetes CronJob to schedule the command. The command is fired as wished, but when it tries to send the notifications i got this error :

swift 550 5.7.1 Relaying denied

I tried with 2 differents MAIL_HOST (ssl0.ovh.net and smtp.gmail.com). Both use SMTP.

Any help appreciated !

Thanks in advance, Julien


Solution

Ok i had to add my env variables in the cron config file



Answered By - jurandou
Answer Checked By - Timothy Miller (WPSolving Admin)