Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

stueynet's avatar

Email templates are not updating on Production

I am running Laravel on a production server. I have set it up to work a lot like Envoyer whereby we pull the new code to a new folder and then update the symlink to it once the process is complete. The /storage directory exists outside of the releases folders so all releases have access.

For some reason, when we deploy new code, the email templates do not update. Emails get sent out with the old wrappers / content. However all normal blade templates update just fine. I have even manually deleted the storage/framework/cache and storage/framework/views manually and still it sends an old version of email templates.

Does anyone have any clue as to how this is even possible? Is this relating to some caching at Mailgun? I am completely stumped here.

0 likes
6 replies
SaeedPrez's avatar

Not sure why it would do that but is it possible for you to also run php artisan view:clear when updating the symlink?

stueynet's avatar
stueynet
OP
Best Answer
Level 5

Actually I figured it out. The issue is insanely weird but for any nerds who care I will explain:

I had another codebase installed at /var/www/oldapp. My supervisord config was referencing that. So somehow because of that, emails were getting sent using the views form that old application. But everything was still working other than that. Very strange indeed. Anyway I updated my supervisord config to run artisan within /var/www/current and all is good now.

Thanks!

3 likes
lasse's avatar

Restarting the queue daemon worker fixed the problem for me.

2 likes
dineshsuthar92's avatar

It solved my problem. I had to restart my queue.

php artisan queue:work

1 like
Snapey's avatar

@bliss things change over time, which is why its pointless commenting on a 7 year old thread.

Please or to participate in this conversation.