Google App
Google App
Agenda:
1) Install Google Cloud SDK
2) Account Login
3) Project Creation
4)Creating Sample Hello world
Python program
5) Run the program in GAE
INTRODUCTION
• Google App Engine is a cloud computing
platform as a service for developing and
hosting web applications in Google-managed
data centers. Applications are sandboxed and
run across multiple servers.
Installation
• download link
INITIALIZATION AND SETUP
• Command to initialize the cloud
gcloud init
• create configuration
• Account login
• project creation
gcloud projects create [Project ID]
gcloud projects list
gcloud config set project [Project ID]
Python Program
import webapp2
class MainPage(webapp2.RequestHandler):
def get(self):
self.response.write("Hello world“)
app =
webapp2.WSGIApplication([('/',MainPage)],
debug=False)
Yaml Configuration
runtime: python27
api_version: 1
threadsafe: false handles multiple request
handlers:
- url: / root URL Path
script: test.app Python file to be run
Run in GAE
Command for Local server
python dev_appserver.py path-to-project
directory
Command for Deploy in Cloud
gcloud app deploy