PHP 7.2 was released in November of 2017.
There is an "official" docker image for PHP 7.2 (as well as 7.1, etc.) that is maintained by the Docker community:
https://hub.docker.com/_/php/
PHP 7.2 was released in November of 2017.
There is an "official" docker image for PHP 7.2 (as well as 7.1, etc.) that is maintained by the Docker community:
https://hub.docker.com/_/php/
Change 449033 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[operations/docker-images/toollabs-images@master] [WIP] Add php72 base and web images
Change 449033 merged by jenkins-bot:
[operations/docker-images/toollabs-images@master] Add php72 base and web images
Change 452353 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[operations/software/tools-webservice@master] Add support for php7.2 image/backend
Change 452353 merged by jenkins-bot:
[operations/software/tools-webservice@master] Add support for php7.2 image/backend
tools.wmde-access@tools-bastion-03:~$ webservice --backend=kubernetes php7.2 start Starting webservice....
https://tools.wmflabs.org/wmde-access/ now works :) Thanks!
It's still very much alpha quality for now, there's still some stuff missing. I hope to send out an announcement calling for beta testers later this week.
Great to see this moving forward ( so quickly \o/ ) - I just tried it on one of our existing tools ( that we also need to upgrade ). Three things:
1st mbstring:
You are missing a required extension to PHP that MediaWiki requires to run. Please install: mbstring (more information)
2nd update:
When php7.2 is only available via the webservice how can I run the maintanace script that requires php7x on CLI?
3rd composer:
our requirements could not be resolved to an installable set of packages. Problem 1 - This package requires php >=5.6.99 but your PHP version (5.5.9) does not satisfy that requirement. Problem 2 - Installation request for mediawiki/mediawiki-codesniffer 21.0.0 -> satisfiable by mediawiki/mediawiki-codesniffer[v21.0.0]. - mediawiki/mediawiki-codesniffer v21.0.0 requires php >= 5.6.99 -> your PHP version (5.5.9) does not satisfy that requirement.
@WMDE-Fisch for 2 and 3 you can probably use webservice --backend=kubernetes php7.2 shell? That’s what this guide recommends for Python tools, at least.
Change 452755 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[operations/docker-images/toollabs-images@master] php72: Install php7.2-mbstring
Change 452755 merged by jenkins-bot:
[operations/docker-images/toollabs-images@master] php72: Install php7.2-mbstring
Added. You'll need to run webservice restart for it to show up.
When php7.2 is only available via the webservice how can I run the maintanace script that requires php7x on CLI?
Exactly what @Lucas_Werkmeister_WMDE said - you should use the shell interactive pod to get a PHP 7.2 CLI. It also has composer installed.
Cool, that works. Thank you. - Only when running composer to update all the stuff I got several of these:
Failed to download wikimedia/html-formatter from dist: The zip extension and unzip command are both missing, skipping.
It went through anyways ( I think by downloading it unzipped from source or something?) and the wiki is up and running:
https://tools.wmflabs.org/wmde-editconflict-test/core/index.php?title=Spezial:Version \o/
Yep, looks like the zip extension is missing. For completeness:
--- 56.txt 2018-08-15 12:29:22.815823579 -0700 +++ 72.txt 2018-08-15 12:29:48.039927871 -0700 @@ -1,16 +1,11 @@ [PHP Modules] -apc apcu -bcmath -bz2 calendar Core ctype curl date -dba dom -ereg exif fileinfo filter @@ -19,14 +14,10 @@ gettext hash iconv -imagick intl json libxml mbstring -mcrypt -mhash -mysql mysqli mysqlnd openssl @@ -40,13 +31,12 @@ Phar posix readline -redis Reflection session shmop SimpleXML -soap sockets +sodium SPL sqlite3 standard @@ -60,7 +50,6 @@ xmlwriter xsl Zend OPcache -zip zlib [Zend Modules]
Change 453064 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[operations/docker-images/toollabs-images@master] php72: Add more missing extensions that php5.6 had
Change 453064 merged by jenkins-bot:
[operations/docker-images/toollabs-images@master] php72: Add more missing extensions that php5.6 had
Tested composer, works fine with the unzip binary:
tools.phpinfo@interactive:~$ composer install Loading composer repositories with package information Updating dependencies (including require-dev) Package operations: 1 install, 0 updates, 0 removals - Installing wikimedia/timestamp (v1.0.0): Downloading (100%) Writing lock file Generating autoload files
Is the Redis extension able to be enabled now that T200666 is resolved? Or is there more to it? (I'm happy to help, if someone points me in the right direction.)
Sorry, not yet, still a missing dependency that I didn't realize earlier :/ see T202704: Add a few more PHP 7.2 packages for Toolforge in thirdparty/php72.
Change 455083 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[operations/docker-images/toollabs-images@master] php72: Pin thirdparty/php72 higher than stretch
Change 455084 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[operations/docker-images/toollabs-images@master] php72: Enable imagick, update missing extension reasons
Change 455083 merged by jenkins-bot:
[operations/docker-images/toollabs-images@master] php72: Pin thirdparty/php72 higher than stretch
Change 455084 merged by jenkins-bot:
[operations/docker-images/toollabs-images@master] php72: Enable apc, apcu, imagick, & redis
Scratch that, Moritz was faster than I expected, so the packages are available, and I just updated the docker containers. https://tools.wmflabs.org/phpinfo/ shows redis :)
@Samwilson give it a spin and let me know how it goes? If you already have a running webservice, you'll need to restart it to pick up the updated image AIUI.
Is it possible to send mail from the php7.2 container? (I'm getting "/usr/sbin/exim: No such file or directory" and there doesn't seem to be any obvious other mail agent to use.)
Is it possible to send mail in the 5.6 container? If so, then I'll look into why it's not working in 7.2. But if it's not possible in 5.6, then can you file it as a separate ticket?
Good point, I should have checked that. It's not possible with php5.6, so I've created T205813: Document mail relay service which can be used to send outbound email from Toolforge Kubernetes containers.
Thanks.
Change 496564 had a related patch set uploaded (by BryanDavis; owner: Bryan Davis):
[operations/software/tools-webservice@master] kubernetes: Set php7.2 as the default type