mardi 21 mars 2017

Laravel 5.1 asset() not working in ssl enabled ec2 instance

I am using aws EC2 instance for my laravel project and installed ssl certificate using load balancer for website. After activating ssl on ec2 instance for my website, laravel asset() for javascript and css taking http not https. Beacuse of this website unable to find js and css files and website looks completely weird. I know that secure_asset() is available for https but in localhost it will not work. When I was hosting same website in Godaddy VPS with ssl it was not showing any error for asset() but in ec2 its taking incorrect path. Laravel asset() takes both http or https based on the url.

I am using ubuntu OS with nginx server installed and php 7.0. Is there any extra steps we have to perform for laravel in ec2 or nginx for ssl to work properly. I will be happy if somebody helps me get solution. Thank you in advance.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire