如何创建 SQL 到我的应用程序的连接并将其上传到 google 云
How do I create SQL connection to my app and Upload it to google cloud
感谢您回复我。抱歉回复晚了,这次是睡觉时间。我需要将我创建的 Cloud SQL 数据库连接到 App Engine 中的应用程序。我尝试按照在线教程进行操作,但是当我应用此类信息时,我会得到 gcloud app deploy return 连接错误。请帮忙。还要在这里澄清一下:当我执行 gcloud app deploy 命令时,我想它会将我的本地文件带到 Google Cloud,在那里我会在我正在部署的项目上看到我的项目的整个文件夹和文件,但我看到的是旧的我的项目版本,而演示文稿已更改为最新版本。还有最后一个我如何 link 来自 http://domain.google.com to my app in http://cloud.google.com 的域名。请帮帮我,我一直在这里努力,压力快要死了
鉴于您没有提供任何关于您正在使用什么设置或提供了什么错误的信息,因此不可能知道您 运行 遇到了什么样的问题。
我建议查看 "Connecting to App Engine" 页面 here。它应该可以回答您关于从 App Engine 应用程序进行连接的许多问题。
我看到这里有两个问题。
1.
I need to connect the Cloud SQL database that I have created to my
application that is in App Engine. I tried to follow the online
tutorials but when I do apply such info I would get then gcloud app
deploy it return a connection error. Please help. Also clarify here:
When I execute the gcloud app deploy command I suppose it takes my
local file to Google Cloud where I would see the entire folder and
files of my project on the project I was deploying but I am seeing the
old version of my project while presentation has changed to the latest
version.
我在这里看到您的问题与 CloudSQL 和 GAE 连接有关。根据您使用的是 GAE Standard 还是 Flex 和 CloudSQL MySQL 还是 POSTGRES,步骤会有所不同。虽然这里的文档很清楚。
2.
Also last one how can I link domain nam from http://domain.google.com
to my app in http://cloud.google.com . Please help I am dying with
stress I have been trying in here
这将非常简单,转到 GCP 云控制台,导航到 GAE-->设置-->自定义域,然后单击添加自定义域 "Enter the domain name you want to link" 当你单击继续时,你将看到验证域所有权并将 DNS 指向 GAE 的步骤。
由 GCP 人员在 https://cloud.google.com/appengine/docs/standard/python/mapping-custom-domains
正确记录
如果您使用的是 GAE Standard 或 Flex,则命令 gcloud app deploy 的可能结果:
需要 app.yaml(或 appengine-web.xml)文件才能将此目录部署为 App Engine 应用程序,检查下一个链接:
https://cloud.google.com/appengine/docs/flexible/python/configuring-your-app-with-app-yaml
https://cloud.google.com/appengine/docs/flexible/python/writing-application-logs
Mysql 和 Postgres 连接:
https://cloud.google.com/sql/docs/mysql/connect-app-engine
https://cloud.google.com/sql/docs/postgres/connect-app-engine
有时分享 app.yaml 以正确复制应用程序很容易。
感谢您回复我。抱歉回复晚了,这次是睡觉时间。我需要将我创建的 Cloud SQL 数据库连接到 App Engine 中的应用程序。我尝试按照在线教程进行操作,但是当我应用此类信息时,我会得到 gcloud app deploy return 连接错误。请帮忙。还要在这里澄清一下:当我执行 gcloud app deploy 命令时,我想它会将我的本地文件带到 Google Cloud,在那里我会在我正在部署的项目上看到我的项目的整个文件夹和文件,但我看到的是旧的我的项目版本,而演示文稿已更改为最新版本。还有最后一个我如何 link 来自 http://domain.google.com to my app in http://cloud.google.com 的域名。请帮帮我,我一直在这里努力,压力快要死了
鉴于您没有提供任何关于您正在使用什么设置或提供了什么错误的信息,因此不可能知道您 运行 遇到了什么样的问题。
我建议查看 "Connecting to App Engine" 页面 here。它应该可以回答您关于从 App Engine 应用程序进行连接的许多问题。
我看到这里有两个问题。
1.
I need to connect the Cloud SQL database that I have created to my application that is in App Engine. I tried to follow the online tutorials but when I do apply such info I would get then gcloud app deploy it return a connection error. Please help. Also clarify here: When I execute the gcloud app deploy command I suppose it takes my local file to Google Cloud where I would see the entire folder and files of my project on the project I was deploying but I am seeing the old version of my project while presentation has changed to the latest version.
我在这里看到您的问题与 CloudSQL 和 GAE 连接有关。根据您使用的是 GAE Standard 还是 Flex 和 CloudSQL MySQL 还是 POSTGRES,步骤会有所不同。虽然这里的文档很清楚。
2.
Also last one how can I link domain nam from http://domain.google.com to my app in http://cloud.google.com . Please help I am dying with stress I have been trying in here
这将非常简单,转到 GCP 云控制台,导航到 GAE-->设置-->自定义域,然后单击添加自定义域 "Enter the domain name you want to link" 当你单击继续时,你将看到验证域所有权并将 DNS 指向 GAE 的步骤。 由 GCP 人员在 https://cloud.google.com/appengine/docs/standard/python/mapping-custom-domains
正确记录如果您使用的是 GAE Standard 或 Flex,则命令 gcloud app deploy 的可能结果: 需要 app.yaml(或 appengine-web.xml)文件才能将此目录部署为 App Engine 应用程序,检查下一个链接:
https://cloud.google.com/appengine/docs/flexible/python/configuring-your-app-with-app-yaml https://cloud.google.com/appengine/docs/flexible/python/writing-application-logs
Mysql 和 Postgres 连接:
https://cloud.google.com/sql/docs/mysql/connect-app-engine https://cloud.google.com/sql/docs/postgres/connect-app-engine
有时分享 app.yaml 以正确复制应用程序很容易。