- Lab
- A Cloud Guru
Deploying an App Engine Application
Google Cloud App Engine provides a solid, easy-to-access platform for a wide range of web apps. Its interoperability with other Google Cloud services, such as Cloud Datastore, enhances its effectiveness. In this hands-on lab, we’ll deploy an app to App Engine that allows users to enter details into a NoSQL database, Cloud Datastore, and displays the proper HTML template and CSS. The process requires that we customize the `config.py` file before deploying the app.
Path Info
Table of Contents
-
Challenge
Enable APIs and clone GitHub repository.
- From the main navigation, visit the APIs & Services > Libraries page, and search for "Datastore".
- Select the Cloud Datastore API.
- If the API is not available, click Enable.
- Repeat the process to enable the Cloud Build API and Container Registry API
- Activate the Cloud Shell.
- When it spins up, create the necessary bucket (bucket name must be unique): gsutil mb -c regional -l us-east1 gs://[BUCKET_NAME] gsutil iam ch allUsers:objectViewer gs://[BUCKET_NAME]
- Clone the GitHub repository: git clone https://github.com/ACloudGuru-Resources/content-gc-essentials
- Change directory to the
content-gc-essentials/app-engine-lab
folder.
-
Challenge
Configure `config.py` file.
- From the Cloud Shell Editor, open
config.py
in theapp-engine-lab
folder. - Change
PROJECT_ID
to the current project, as shown in the Cloud Shell. - Change the "CLOUD_STORAGE_BUCKET" variable value to your unique bucket name.
- Save the file.
- From the Cloud Shell Editor, open
-
Challenge
Deploy the app.
- In the Cloud Shell, enter the following code:
gcloud config set app/cloud_build_timeout 6000s gcloud app deploy
- When prompted, choose the us-east1 region.
-
Challenge
Test the app.
- In the Cloud Shell, enter the following code:
gcloud app browse
- If the browser window does not open, click the generated link.
What's a lab?
Hands-on Labs are real environments created by industry experts to help you learn. These environments help you gain knowledge and experience, practice without compromising your system, test without risk, destroy without fear, and let you learn from your mistakes. Hands-on Labs: practice your skills before delivering in the real world.
Provided environment for hands-on practice
We will provide the credentials and environment necessary for you to practice right within your browser.
Guided walkthrough
Follow along with the author’s guided walkthrough and build something new in your provided environment!
Did you know?
On average, you retain 75% more of your learning if you get time for practice.