Analysis of running problems of Laravel Sail Docker on local host
P粉953231781
P粉953231781 2023-08-14 14:50:10
0
1
593
<p>I downloaded the Windows version of Docker and installed it successfully, I created a new Laravel project and installed Sails, the installation was successful. </p> <p>But when I run the "sails up" command (sails is an alias), and then type localhost in the browser, it takes me to an Ubuntu page instead of the Laravel homepage, and if I use Laravel.test, A not found error page will be displayed. </p> <p>How can I solve this problem. </p> <pre class="brush:php;toolbar:false;">.[[enter image description here](https://i.stack.imgur.com/AmBIY.jpg)](https://i. stack.imgur.com/uYH2a.jpg)</pre> <p><br /></p>
P粉953231781
P粉953231781

reply all(1)
P粉547170972

You can try editing your APP_PORT in your .env file, like this:

APP_PORT=3001 // 或者你喜欢的任意端口号

Afterwards you can re-run your sail command:

sail up

Now, you should be able to access your website via localhost:3001.

The reason why your sail up command fails may be because your PORT number 80 has been used by other software (such as nginx or apache) is occupied.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template