Laravel Forge fails to provision servers on AWS

Published under Laravel.

If you're running into issues with Laravel Forge failing to provision your server when using AWS, chances are there is an easy fix.

When provisioning a new server from within the Laravel Forge UI, Forge will default to creating a new VPC for your server. This is great because it means Forge sets up the VPC the way it wants. However, if you happen to ask Forge to use the default VPC that is created with your AWS account, you'll run into a problem where Forge fails to provision the server, and then just deletes the server from Forge.

The issue with the default VPC in AWS is that the default security group it uses only allows inbound traffic from within that security group. This essentially tells AWS to keep everything within the VPC as private (no outside access). Since the Forge servers are located outside of your VPC, Forge is unable to make contact with your new server, so it thinks it failed to provision.

The fix

You have two options for a fix:

  1. Allow Forge to create a new VPC

  2. If you insist on using the default VPC, change the security group to allow inbound traffic from anywhere instead of from within the security group


Thanks for reading!

Did you find this post useful? Let me know on Twitter! If you found an issue with the content, submit a pull request!

Subscribe to my newsletter to know when I publish more content in the future.

❤️ Likes: 0
📣 Retweets: 0
💬 Replies: 0
🙊 Mentions: 0