Closed narration-sd closed 7 years ago
unfortunately this is going to be an apache limitation since PHP version is a server configuration VS nginx a site configuration option.
We should get something added to the Docs that mentions this. (Probably). Sorry for the issues!
@svpernova09 Understood, as things stand, but here are several notes on people actually doing this, mostly around fastcgi.
It would certainly be great that Homestead supported this, hope you would agree, as people need to use it to try out deployment situations, many of which don't move from Apache, however advantageous Nginx.
I'll put the phpfarm one first; not sure if it isn't a simplifying layer for fastcgi:
@narration-sd I totally get it, and I'm sorry for the frustration, but at the moment it's not an easily feasible option. Compiling PHP versions is just another step outside of what's going to be easy maintainable for me for Homestead. Sticking to PPAs is what makes this entire project a lot easier to handle.
My best recommendation would be installing Homestead per project per each version of PHP you need and run each of those on their own version of PHP.
@svpernova09 Ok, Joe, and do appreciate the profusion issue.
What about just doing php5.6 plus whatever the latest php7 is? That one is still quite important in view of legacy hosting sites, which move very slowly as you will know?
That Sury guy has a 5.6 ppa, and has been very good about keeping it up, even with sort of edge things as the php5.6-sybase (which is dblib to access mssql databases) that I need....
The primary thing I want to avoid is compiling PHP for Homestead. It's so much easier to debug knowing that PHP is coming from a PPA and Ondřej is the gold standard. Atm we're actually supporting old versions of PHP in 2 ways, old versions of PHP where I maintain a personal box for 5.x and official Homestead box versions for 7.0.
I'm just at my limit it what I can support with the best user experience for Homestead.
Ok, thanks for listening, Joe, and very much appreciated to use Homestead, especially in its recent form.
Not having a central vm has made matters much smoother, faster, and generally enjoyable -- thanks.
Thanks for the kind words, it certainly makes it worth it :D
I hate to say no to stuff, especially knowing it'll help people, but we have to balance that with what keeps it easy to maintain across 3 OS's and 3 providers.
Cheers.
Yeah, I know :)
You take care, Joe -- Clive
Is the compiling step really required? @narration-sd check my https://github.com/laravel/homestead/issues/756#issuecomment-350548939 to see how to switch default php version
That's not true. You could run multiple php verisons inside different apache sites using php-fpm.
We did it already in our production environment. So, please fix it in homestead, too.
We did it already in our production environment. So, please fix it in homestead, too.
Pull requests are always welcome.
Versions
Host operating system
Homestead.yaml
ip: 192.168.10.15 memory: 2048 cpus: 1 provider: virtualbox authorize: ~/.vagrantssl/id_rsa.pub keys:
do build empty storage and cp_resources folders for Craft's needs
sites:
map: sch.dev to: /home/vagrant/staging_constantholidays_html/public type: apache php: "5.6" params:
map: sch2.dev to: /home/vagrant/staging_constantholidays_html/public type: apache php: "7.0" params:
databases:
Vagrant up output
https://gist.github.com/narration-sd/21158af0a0aef7cd34834ca399901a0b
Expected behavior
I should get two sites, sch.dev and sch2.dev, one running php5.6 apache, the other php7.0 apache
Actual behavior
Both sites run php5.6 apache, according to phpinfo() and actual site content reaction
Steps to reproduce
References
https://github.com/laravel/homestead/issues/625 -- using the workaround vaguely noted in #625, via some explanation of syntax here: https://laravel.com/docs/5.4/homestead#site-parameters