Hi supporter,
I am in deploy the Laravel app on my droplets. I use the php artisan serve to run the server, but I could not access it by IP and port(8000).
Can you give me any ideas?
Regards.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there,
It sounds like that the port might not be opened via your firewall. If you are using a firewall like ufw you can open the port with the following command:
ufw allow 8000
Also keep in mind that you might have to bind it on 0.0.0.0 rather than localhost:
php artisan serve --host 0.0.0.0
That way the Laravel installation will be accessible externally via your server IP as well.
Let me know how it goes. Regards, Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.