I made some good steps.
I can make a port forwarding on homestead.rb like:
config.vm.network "forwarded_port", guest: 4000, host: 4000
So I can run my angular app and I can access it via homestead.app:4000 or even localhost:4000. So far, so good.
To make angular proxy the requests to the laravel app, I proxy them to the port 80 and it works, but when I add another app, the angular app will then proxy to that new app.
Even when I can do
homestead.app:8000
or
app2.app:8000
And get different apps, seems like in the VM they both run on the port 80 so I can't tell my angular app what app to use as a proxy API.
Ideas?
I got the answer thanks to @trq at laravel irc channel.
I can use the hostname (homestead.app) and also the port so I get redirected to the app I need.
Fantastic.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community