cretueusebiu / valet-windows
A more enjoyable local development experience for Windows.
Installs: 109 655
Dependents: 0
Suggesters: 0
Security: 0
Stars: 913
Watchers: 21
Forks: 697
Open Issues: 14
Requires
- php: ^7.4|^8.0
- illuminate/collections: ^8.0|^9.0|^10.0
- illuminate/container: ^8.0|^9.0|^10.0
- mnapoli/silly: ^1.7
- nategood/httpful: ^0.3
- phpseclib/phpseclib: ^3.0
- symfony/process: ^4.0|^5.0|^6.0
Requires (Dev)
- illuminate/testing: ^8.20|^9.0|^10.0
- mockery/mockery: ^1.4
- phpunit/phpunit: ^8.5|^9.5
- spatie/docker: ^1.7
- dev-master / 2.x-dev
- 2.5.2
- 2.5.1
- 2.5.0
- 2.4.1
- 2.4.0
- 2.3.2
- 2.3.1
- 2.3.0
- 2.2.0
- 2.1.5
- 2.1.4
- 2.1.3
- 2.1.2
- 2.1.1
- 2.1.0
- 2.0.15
- 2.0.14
- 2.0.13
- 2.0.12
- 2.0.11
- 2.0.10
- 2.0.9
- 2.0.8
- 2.0.7
- 2.0.6
- 2.0.5
- 2.0.4
- 2.0.3
- v1.0.8
- v1.0.7
- v1.0.6
- v1.0.5
- v1.0.4
- v1.0.3
- v1.0.2
- v1.0.1
- v1.0.0
- v0.1.8
- v0.1.6
- v0.1.5
- v0.1.3
- v0.1.2
- v0.1.1
- v0.1.0
This package is auto-updated.
Last update: 2024-11-06 10:58:59 UTC
README
Windows port of the popular development environment Laravel Valet.
Introduction
Valet is a Laravel development environment for Windows. No Vagrant, no /etc/hosts
file. You can even share your sites publicly using local tunnels. Yeah, we like it too.
Laravel Valet configures your Windows to always run Nginx in the background when your machine starts. Then, using Acrylic DNS, Valet proxies all requests on the *.test
domain to point to sites installed on your local machine.
Documentation
Before installation, make sure that no other programs such as Apache or Nginx are binding to your local machine's port 80.
Also make sure to open your preferred terminal (Windows Terminal, CMD, Git Bash, PowerShell, etc.) as Administrator.
- If you don't have PHP installed, open PowerShell (3.0+) as Administrator and run:
Set-ExecutionPolicy RemoteSigned -Scope Process; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12; Invoke-WebRequest -Uri "https://github.com/cretueusebiu/valet-windows/raw/master/bin/php.ps1" -OutFile $env:temp\php.ps1; .$env:temp\php.ps1 "8.3"
(You can replace 8.3
with the PHP version you want to install: 7.4
, 8.0
, 8.1
, 8.2
, 8.3
)
This script will download and install PHP for you and add it to your environment path variable. PowerShell is only required for this step.
-
If you don't have Composer installed, make sure to install it.
-
Install Valet with Composer via
composer global require cretueusebiu/valet-windows
. -
Run the
valet install
command. This will configure and install Valet and register Valet's daemon to launch when your system starts. -
If you're installing on Windows 10/11, you may need to manually configure Windows to use the Acrylic DNS proxy.
Valet will automatically start its daemon each time your machine boots. There is no need to run valet start
or valet install
ever again once the initial Valet installation is complete.
For more please refer to the official documentation on the Laravel website.
Known Issues
- WSL2 distros fail because of Acrylic DNS Proxy (microsoft/wsl#4929). Use
valet stop
, start WSL2 thenvalet start
. - The PHP-CGI process uses port 9001. If it's already used change it in
~/.config/valet/config.json
and runvalet install
again. - When sharing sites the url will not be copied to the clipboard.
- You must run the
valet
commands from the drive where Valet is installed, except for park and link. See #12. - If your machine is not connected to the internet you'll have to manually add the domains in your
hosts
file or you can install the Microsoft Loopback Adapter as this simulates an active local network interface that Valet can bind too.
Xdebug
To enable a debugging session you can use Xdebug helper or set a cookie with the name XDEBUG_SESSION
.
Testing
Run the unit tests with:
composer test-unit
Before running the integration tests for the first time, you must build the Docker container with:
composer build-docker
Next, you can run the integration tests with:
composer test-integration
Changelog
Please see CHANGELOG for more information what has changed recently.
License
Laravel Valet is open-sourced software licensed under the MIT license.