Hi I'm using amazon web services elastic beanstalk. Everytime I use git aws.push, my php application uploads successfully However, when I click on the url it says
Forbidden You don't have permission to access / on this server.
My server specs:
64bit Amazon Linux 2014.03 v1.0.2 running PHP 5.4
What would be causing this? Thanks
The "403 Forbidden" error can occur due to the following reasons: Permissions are missing for s3:PutObject to add an object or s3:PutObjectAcl to modify the object's ACL. You don't have permission to use an AWS Key Management Service (AWS KMS) key. There is an explicit deny statement in the bucket policy.
The HTTP 403 Forbidden error most commonly occurs when private DNS is enabled for an API Gateway interface VPC endpoint that's associated with a VPC. In this scenario, all requests from the VPC to API Gateway APIs resolve to that interface VPC endpoint.
Credit to Rakesh Bollampally:
I think your application is inside a folder. If that is the case, change the EBS configuration for document root or have a file in root to redirect to that sub folder. To Change document root, go to EBS console>Application>configuration>Software configuration and change the "Document root" under "container options"
If your laravel project is in a folder called AppFolder for instance on your local drive, do not generate your zip file by rightclicking on AppFolder. Use the below instead.
Open the AppFolder, highlight all files (includes your public folder) and select to add to anyName.zip (anyName can be AppFolder also). Upload this anyName.zip to your Beanstalk environment.
You may change the document root to '/public' go to EBS console>Application>configuration>Software configuration and change the "Document root" under "container options"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With