Why Is Runtime PHP 7.0.30 Not 7.2??

62 views
Skip to first unread message

We Are Vitall

unread,
Oct 23, 2018, 9:08:18 AM10/23/18
to Google App Engine
Deploying my app is driving me crazy, getting composer errors due to needing latest php version.

So I have stripped it right back to the following to troubleshoot & still getting this problem:

In empty /home directory
Put the app.yaml - with just the following in it
runtime: php72


Then run:  gcloud app deploy

Check version in console:  Version 20181023t105100  Serving runtime php72

But when I run php -i in console:
PHP Version => 7.0.30-0+deb9u1


WTF?!!


Aref Amiri (Cloud Platform Support)

unread,
Oct 24, 2018, 1:36:06 PM10/24/18
to Google App Engine
By running the php -i command in your Google Cloud Console, this will only display the information related to the php version running on the Google Cloud Shell, which is basically the command line environment for your Cloud Console. Once the application is deployed, it will be deployed to your instances and that's where you specify the runtime environment of your application in your configuration file, which in this case is php72.

ihsan berahim

unread,
Oct 24, 2018, 3:53:29 PM10/24/18
to Google App Engine
after you done 'gcloud app deploy'

1) Go ssh your service instance
2) then type 'docker ps' and copy the first instance id (normally)
3) then type 'docker exec -it <the instance id> bash'

i have no issue deploying a lot PHP micro services on GAE. Chill bro.

sami...@google.com

unread,
Oct 25, 2018, 2:05:03 PM10/25/18
to Google App Engine
You are correct, this way you would be able to see the php version information of the Google App Engine Instance in Flexible environment, but it is not applicable for standard environment as there is no way to ssh into App Engine Standard in php 7.2 Runtime. Also, it is not possible to run php -i command in Google App Engine Standard Environment as there is no way to access the instance inside it. If you want to control the version of the PHP runtime on the flexible environment, I would recommend checking this documentation .

We Are Vitall

unread,
Oct 25, 2018, 3:22:58 PM10/25/18
to Google App Engine
Thanks all, an obvious thing re: the PHP version of course I realise now why it was failing.

App now working fine,
Reply all
Reply to author
Forward
0 new messages