简体   繁体   English

如何在Google Compute Engine中使用适用于PHP的Google App Engine SDK

[英]How to use Google App Engine SDK for php in Google Compute Engine

I am new to Google Compute Engine . 我是Google Compute Engine的新手。

I want to use Google Compute Engine VM instance to develop Google App Engine SDK for PHP. 我想使用Google Compute Engine VM实例开发适用于PHP的Google App Engine SDK。

Steps I used to install GAE SDK for PHP in GCE VM instance. 我曾经在GCE VM实例中安装用于PHP的GAE SDK的步骤。

Using SSH connection I opened the terminal. 使用SSH连接,我打开了终端。

user@lamp-bafs:~$  mkdir gaedev

user@lamp-bafs:~$ cd gaedev

user@lamp-bafs:~$ wget -O gae.zip https://storage.googleapis.com/appengine-sdks/featured/google_appengine_1.9.38.zip

user@lamp-bafs:~$ unzip gae.zip

user@lamp-bafs:~$ echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/php

user@lamp-bafs:~$ export PATH="$PATH:/home/gaedev/google_appengine/"

user@lamp-bafs:~$ echo $PATH

user@lamp-bafs:~$ echo $PATH
/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/usr/bin/php:/home/gaedev/google_appengine

user@lamp-bafs:~$ cp -r google_appengine/new_project_template testapp

user@lamp-bafs:~$python google_appengine/dev_appserver.py testapp
INFO 2016-06-22 05:00:00,836 sdk_update_checker.py:229] Checking for updates to the SDK.WARNING 2016-06-22 05:00:02,159 simple_search_stub.py:1146] Could not read search indexes from /tmp/appengine.new-project-template.user/search_indexesINFO 2016-06-22 05:00:02,170 api_server.py:205] Starting API server at: http://localhost:37210INFO 2016-06-22 05:00:02,177 dispatcher.py:197] Starting module "default" running at: http://localhost:8080INFO 2016-06-22 05:00:02,179 admin_server.py:116] Starting admin server at: http://localhost:8000

After this nothing happened. 此后什么也没发生。 I don't know how to run appengine php project using SSH. 我不知道如何使用SSH运行appengine php项目。

Please anyone help me. 请任何人帮助我。 Is it possible can use Google appengine SDK for PHP in GCE VM instance ? 是否可以在GCE VM实例中使用适用于PHP的Google appengine SDK

Reply to All: 回复全部:

Thanks to all members who replied sincerely. 感谢所有真诚回答的成员。 Basically, What we want to achieve is: 基本上,我们要实现的目标是:

  1. We are a team of 10 developers and want to develop PHP on GAE using the same SDK version from a remote server. 我们是一个由10名开发人员组成的团队,希望使用来自远程服务器的相同SDK版本在GAE上开发PHP。

  2. So, we want to install the GAE PHP SDK on the remote GCE instance once. 因此,我们希望一次在远程GCE实例上安装GAE PHP SDK。

  3. Subsequently, all developers will use that remote PHP SDK installed in that GCE instance. 随后,所有开发人员将使用该GCE实例中安装的该远程PHP SDK。

This is to avoid installing or working in different versions of GAE SDK in our individual local machines. 这是为了避免在我们的本地计算机上安装或使用不同版本的GAE SDK。 We don't want to install in each of our local machines, whenever there is a new Release of GAE SDK. 每当有新的GAE SDK版本发布时,我们都不想在每台本地计算机上安装。 We just want to update once in GCE instances, with the new GAE SDK in one centralized place, to ensure all developers develop the code using the same version of GAE SDK. 我们只想在GCE实例中更新一次,并在一个集中的位置使用新的GAE SDK,以确保所有开发人员都使用相同版本的GAE SDK开发代码。 We also don't want to waste time to install SDK in each machine to ensure consistency in development environments. 我们也不想浪费时间在每台机器上安装SDK,以确保开发环境中的一致性。

In this context, can you please enlighten us to centralize our GAE SDK in GCE development server? 在这种情况下,您能启发我们将我们的GAE SDK集中在GCE开发服务器中吗?

Thanks very much in advance, 首先十分感谢,

I'd advise using git for collaborative development, while managing using the latest SDK is relatively simple. 我建议使用git进行协作开发,而使用最新的SDK进行管理相对简单。 I'd say this open-endeed question would have been better posted to the Google App Engine Group , which is meant for more general questions about development, the platform and services, etc. Stack Overflow requires concrete technical question-answer format, and the rules advise closing questions which are about general development advice. 我想说,这个开放的问题最好发布到Google App Engine组中 ,这是有关开发,平台和服务等的更一般性的问题。Stack Overflow需要具体的技术问答格式,并且规则建议有关一般发展建议的最后问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM