valet-linux icon indicating copy to clipboard operation
valet-linux copied to clipboard

Question: Will you support valet 3?

Open timvanuum opened this issue 2 years ago • 7 comments

No rush, but just the question if you are going to support valet 3. https://laravel-news.com/laravel-valet-3-0-0

Thanks for the work so far! :)

timvanuum avatar Mar 30 '22 15:03 timvanuum

Not right now, I think this will need a lot of work or even a re-base from origin in order to get the same results.

Many package managers do not support PHP Multi-version as per default. Homebrew may be an option but it does not seem to work for everyone as expected.

jmarcher avatar Mar 30 '22 15:03 jmarcher

Not right now, I think this will need a lot of work or even a re-base from origin in order to get the same results.

Many package managers do not support PHP Multi-version as per default. Homebrew may be an option but it does not seem to work for everyone as expected.

On debian based distros there is the sury repo that contains multiple versions of php, nginx, etc. Also there is a PPA still from sury. https://deb.sury.org https://launchpad.net/~ondrej/+archive/ubuntu/php/

For fedora and arch + derivates i don't know really.

I'm on an ubuntu based distro with that repos, and now i switch with the use command the php version.

sergix44 avatar Mar 31 '22 13:03 sergix44

Many package managers do not support PHP Multi-version as per default. Homebrew may be an option but it does not seem to work for everyone as expected.

Would something like something like phpenv be better than catering to individual distros package managers?

As of now, I have switched (almost) completely to using only phpenv + php-build (via phpenv-installer) to manage my php installations. I am running on Arch. While Arch does have multiple versions vie the official repository and AUR, managing multiple php versions using phpenv is a lot easier.

https://github.com/phpenv/phpenv https://github.com/php-build/php-build https://github.com/phpenv/phpenv-installer

hakimzulkufli avatar Apr 15 '22 13:04 hakimzulkufli

I was reading at laravel valet's isolate function (which allows to run php-fpm multiple versions). At first , it doesn't seems too hard to implement: just generate a nginx conf file for isolated site, which is using a socket instead of a port bind to php-fpm.

Haven't looked too far in you valet implementation, but just seen that you need to implement all distros package manager as wrappers (MacOs only use brew version).

Just a quick idea : would it be possible to use brew on linux instead of native package manager ? It did not had any look, either don't know if it would allow to update nginx/dnsmasq configuration, etc... I might fire a VM and give it a try ! Edit : Just installed a brand new Ubuntu VM, installed brew inside it, then PHP, then composer, then ran "composer global require laravel/valet". Got a first error telling me "php not found"... Made a symlink from brew's php version to /usr/bin/php , ran again, then "Only Mac is supported...."... So to go a bit further, I must first clone the original repo, then remove this test.... but I'm 99.99% sure I'll run into issues about running dnsmasq or other...

Adesin-fr avatar Jul 26 '22 08:07 Adesin-fr

I was reading at laravel valet's isolate function (which allows to run php-fpm multiple versions). At first , it doesn't seems too hard to implement: just generate a nginx conf file for isolated site, which is using a socket instead of a port bind to php-fpm.

Haven't looked too far in you valet implementation, but just seen that you need to implement all distros package manager as wrappers (MacOs only use brew version).

Just a quick idea : would it be possible to use brew on linux instead of native package manager ? It did not had any look, either don't know if it would allow to update nginx/dnsmasq configuration, etc... I might fire a VM and give it a try ! Edit : Just installed a brand new Ubuntu VM, installed brew inside it, then PHP, then composer, then ran "composer global require laravel/valet". Got a first error telling me "php not found"... Made a symlink from brew's php version to /usr/bin/php , ran again, then "Only Mac is supported...."... So to go a bit further, I must first clone the original repo, then remove this test.... but I'm 99.99% sure I'll run into issues about running dnsmasq or other...

It's a known issue that linux-homebrew php doesn't work with linux-valet. Only solution is to install php via apt-get.

the-programmer-alex avatar Oct 04 '22 05:10 the-programmer-alex

Hi there !

I've merge a first "draft" of valet's 3 "isolate" function into master branch.

If some of you can help me to test and find bugs ;)

Please feel free to comment !

PS : a small update : I've just fixed it right now, it was pretty broken ! PS2 : A note about "secure" command : like Laravel's valet 3, secure and isolate are not compatible together. I should make a small change to allow both to work together...

Adesin-fr avatar Dec 06 '22 09:12 Adesin-fr

@Adesin-fr please check #401 because the master wont work with links isolation now ;D

joke2k avatar Dec 06 '22 13:12 joke2k