Fayakon
Fayakon

Reputation: 1523

Laravel error: Laravel Sail no such File or directory found

I am following this tutorial,

I installed Docker and WSL2(Ubuntu 20.04.4 LTS) on my windows system, as shown in image below, enter image description here

When i am trying to run Laravel project using command,

./vendor/bin/sail up

Why i am getting error no such file or directory found?

Upvotes: 19

Views: 30318

Answers (3)

Getoar Kastrati
Getoar Kastrati

Reputation: 91

This worked for me:

Step 1

In your terminal, run this to open your .bash_profile file :

nano ~/.bash_profile

And paste this :

if [ -r ~/.bashrc ]; then
    source ~/.bashrc
fi

Exit and save the modification.

Step 2

Still in your terminal, run this to open your .bashrc file :

nano ~/.bashrc

And paste this :

alias sail='bash vendor/bin/sail'

Exit and save the modification.

Step 3

You can now open any Laravel project using Sail and write the following command to start it :

sail up

Or to run it on background:

sail up -d

I'm using Ubuntu 20.04 on WSL2

Upvotes: 3

username404
username404

Reputation: 329

composer update && npm install worked for me

Upvotes: 5

steven7mwesigwa
steven7mwesigwa

Reputation: 6690

Instead of:

./vendor/bin/sail up ❌

Use this:

bash ./vendor/laravel/sail/bin/sail up ✅

Upvotes: 50

Related Questions