Yeah manage them separately on different VM's or containers. I try to spec my VM's out as close to the production server's specs as possible to try and minimize the "Well, it worked on my system" syndrome. That means potentially dozens of different settings and versions all down the LAMP stack to and including the Linux operating system. This could mean a lot of different instances. This is why I got familiar with Vagrant. Or even easier learn Docker and build containers. They are fast and very efficient.--On Tue, Sep 27, 2016 at 6:13 PM, JD Austin <jd@twingeckos.com> wrote:I typically use virtual machines for this because the production environment won't have both versions and the interdependence issues you can run into having conflicting packages from both versions of PHP can be infuriating. Make a VM with PHP 5.6, get the app working, clone the VM, upgrade PHP to version 7, fix whatever issues you have to, have your firewall port forward to each VM.JDOn Tue, Sep 27, 2016 at 5:56 PM, Keith Smith <techlists@phpcoderusa.com> wrote:
Interesting approach!! Thank you for your feedback!!Keith Smith
On 2016-09-27 09:41, Matt Graham wrote:
On 2016-09-26 20:24, Keith Smith wrote:
I need to test using PHP 5.6 and PHP 7. I have a computer that I will
be configuring as a test server. I will make [it] public facing
periodically - just for testing and for a short time. I want to use
Ubuntu 16.4.
Is there any way to configure one server to give access to two
different versions of PHP, possibly by some Apache config?
I tried to have apache load modules for PHP 5.6 and 7 at the same time
and got segfaults for my trouble. It's probably also not possible to
associate .php files with both versions of the module at the same
time.
That said, there's probably a reasonable way to make this work. Copy
the apache config that's currently working to a separate directory,
like /etc/httpd2/ . Go into that dir and change the Listen port to
something other than 80, like 81. Change the PHP configuration such
that it loads the PHP 7 module instead of the 5.6 module. Change the
ServerRoot to /etc/httpd2 . Change the PidFile to run/httpd2.pid .
Fix the Log directives such that httpd2 isn't writing to the same log
files as the first httpd. Then you can start this alternate apache up
with "apachectl -f /etc/httpd2/conf/httpd.conf", and view how
everything looks in PHP 7 on http://servername:81/whatever.php . (Or
there'll be something I've forgotten, and it'll barf and write stuff
to the error log....)
This is kind of a pain, but it should work properly for testing stuff.
--
---------------------------------------------------
PLUG-discuss mailing list - PLUG-discuss@lists.phxlinux.org
To subscribe, unsubscribe, or to change your mail settings:
http://lists.phxlinux.org/mailman/listinfo/plug-discuss
---------------------------------------------------
PLUG-discuss mailing list - PLUG-discuss@lists.phxlinux.org
To subscribe, unsubscribe, or to change your mail settings:
http://lists.phxlinux.org/mailman/listinfo/plug-discuss James
---------------------------------------------------
PLUG-discuss mailing list - PLUG-discuss@lists.phxlinux.org
To subscribe, unsubscribe, or to change your mail settings:
http://lists.phxlinux.org/mailman/listinfo/plug-discuss