Assignment 1
Assignment 1
Roll no.:-321007
Gr.no.:-21910649
Div:-A
Batch:-B6
Assignment No.1
Title:- Study the Google Cloud Platform.
Theory:-
What Is Cloud Computing?
Cloud computing, in simple words, is accessing and storing data over the Internet
It offers services like storage, database, networking, and more over the Internet to
provide faster, innovative, and flexible resources to its customers. The customers get to
pay only for the resources they use, hence helping them lower their operating costs and
Now, among various cloud providers like AWS, Microsoft, VMWare, IBM, etc., Google
Cloud has been the talk of the town in recent years and there are enough reasons behind
it. Let’s begin with starters and understand what Google Cloud is.
provides various services like compute, storage, networking, Big Data, and many more
that run on the same infrastructure that Google uses internally for its end users like
Google server hasn’t gone down in years. So, if you are planning to run your application
on the Google Cloud infrastructure, then you can be assured of your applications being
(https://cloud.google.com/docs/overview/cloud-platform-services)
This overview introduces some of the commonly used Google Cloud services. For the full
· Storage
· Databases
· Networking
· Big data
· Machine learning
In this section, you'll learn how to create new pre-defined machine types with Compute Engine
from the Cloud Console.
1. In the Cloud Console, on the Navigation menu ( ), click Compute Engine > VM
Instances.
2. To create a new instance, click CREATE INSTANCE.
3. There are many parameters you can configure when creating a new instance. Use the
following for this lab:
4. Click Create.
5. To use SSH to connect to the virtual machine, in the row for your machine, click SSH.
Now you'll install an NGINX web server, one of the most popular web servers in the world, to
connect your virtual machine to something.
1. In the SSH terminal, to get root access, run the following command:
sudo su –
2. As the root user, update your OS:
apt-get update
Expected output
3. Install NGINX:
apt-get install nginx -y
Expected output:
5. To see the web page, return to the Cloud Console and click the External IP link in the
row for your machine, or add the External IP value to http://EXTERNAL_IP/ in a new
browser window or tab.
1. In the Cloud Shell, use gcloud to create a new virtual machine instance from the
command line:
5. You can also use SSH to connect to your instance via gcloud. Make sure to add your
zone, or omit the --zone flag if you've set the option globally:
6. Type Y to continue.
7. Press ENTER through the passphrase section to leave the passphrase empty.
8. After connecting, disconnect from SSH by exiting from the remote shell:
exit
2) App Engine: Qwik Start – Python
The App Engine Admin API enables developers to provision and manage their App Engine
Applications.
4. Click Enable. If there is no prompt to enable the API, then it is already enabled and no
action is needed.
1. From within your helloworld directory where the app's app.yaml configuration file is
located, start the Google Cloud development server with the following command:
dev_appserver.py app.yaml
The development server is now running and listening for requests on port 8080.
2. View the results by clicking the Web preview > Preview on port 8080.
Make a change
1. Click the (+) next to your Cloud Shell tab to open a new command line session.
2. Enter this command to go to the directory that contains the sample code.
cd python-docs-samples/appengine/standard_python3/hello_world
Nano main.py
4. Change “Hello World!” to “Hello Beautiful World!”. Exit and save the file.
5. Reload the Hello World! Browser or click the Web Preview > Preview on port 8080 to
see the results.
Open BigQuery
The BigQuery console provides an interface to query tables, including public datasets offered by
BigQuery.
In the Cloud Console, from the Navigation menu select BigQuery:
The Welcome to BigQuery in the Cloud Console message box opens. This message box provides a link to
the quickstart guide and the release notes.
Click Done.
Once the tables are created the display will be similar to below:
Calculate shot distance and shot angle
2. Click Run.
Calculate shot angle from (x,y) coordinates
1. In the query Editor, click Compose New Query
2. In the query Editor, copy and paste the code:
3. Click Run.
3. Click Run.
3. Click Run.
3. Click Run.
3. Click Run
3. Click Run
Conclusion :- We get hands-on lab practice for gcp . Also get familier with gcp
console.