Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

d-hardin's avatar

Laravel Sail Curl command is asking for uri

I'm trying to get laravel set up with docker in my local environment. I get to the point in the Laravel docs that it wants me to put in curl -s https://laravel.build/example-app | bash and when I do it gives me this

cmdlet Invoke-WebRequest at command pipeline position 1
Supply values for the following parameters:
Uri:

I have no idea what it wants from me and no matter what I type in it gives the following error:

curl : Cannot find drive. A drive with the name 'https' does not exist.

At line:1 char:1
+ curl -s https://laravel.build/example-app | bash
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (https:String) [Invoke-WebRequest], DriveNotFoundException
    + FullyQualifiedErrorId : DriveNotFound,Microsoft.PowerShell.Commands.InvokeWebRequestCommand

I found a potential solution on stackoverflow but it doesn't address the uri part. Am I just missing something super obvious? https://stackoverflow.com/questions/65312815/laravel-installation-sail-problem-23-failed-writing-body

edit:

if I run it as curl.exe -s "https://laravel.build/example-app" | bash (adding .exe to the end of curl) instead I get the following error:

: ambiguous redirect
/bin/bash: line 2: $'\r': command not found
/bin/bash: line 35: syntax error: unexpected end of file
0 likes
5 replies
bobbybouwmann's avatar

Curl is meant for UNIX-based systems, not Windows.

I think you need to use an alternative for windows or install CURL on windows.

This might help (since you use PowerShell): https://www.educative.io/edpresso/curl-in-powershell

There are options to install CURL on windows, you can find those solutions easily by googling around :)

1 like
d-hardin's avatar

I've been on this for hours, and I realized I missed a pretty important line... I was supposed to wsl and run the curl command in the linux os, once I did that I got docker not found messed around trying to figure that out, finally restarted my computer completely and everything appears to be working now. :|

d-hardin's avatar
d-hardin
OP
Best Answer
Level 3

So I'm going to break down the problem I had and the solution, which is embarrassingly simple.

When I first started I walked through laravel's instructions. I downloaded docker desktop, installed a linux OS (Ubuntu to be specific) and configured the WSL on docker. Then I missed this really important line "begin a new terminal session for your WSL2 Linux operating system" and went straight to trying to run curl -s https://laravel.build/example-app | bash which didn't work and gave the issues above.

I figured that maybe I needed to be in the linux os and tried to run the commands there but got 'docker not found'. I went through the WSL stuff again to make sure it was all set up fine, as far as I could tell it was fine.

Once I found out I missed that one line I knew I was on the right track but nothing was working, everything was set fine, WSL was on 2, there was no reason for all of this to have such issues. I finally restarted my computer and brought everything back up and it's now working fine and installing Laravel on the linux os.

tl:dr I didn't begin a new terminal session with WSL2 Linux OS and once I realized my mistake it took a restart of my computer to fix the final issues.

2 likes
islamrobi's avatar

Simple solution is to use git-bash command line tool instead windows powershell.

1 like
barnamah's avatar

@islamrobi when I open the wsl window, I am out of windows file system. how can I install laravel in my windows file system so I can work. or put it this way, where are the laravel files created? this is so confusing.

Please or to participate in this conversation.