Skip to content

Commit 350f252

Browse files
aman-ebaymeredithslotaparthea
authored
docs(samples): update python-api-walkthrough.md (#308)
Enable APIs using gcloud in the Cloud Shell terminal. Update product and links names. Co-authored-by: meredithslota <[email protected]> Co-authored-by: Anthonios Partheniou <[email protected]>
1 parent d00d307 commit 350f252

File tree

1 file changed

+17
-12
lines changed

1 file changed

+17
-12
lines changed

dataproc/snippets/python-api-walkthrough.md

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Estimated completion time: <walkthrough-tutorial-duration duration="5"></walkthr
66

77
This [Cloud Shell](https://cloud.google.com/shell/docs/) walkthrough leads you
88
through the steps to use the
9-
[Google Cloud Client Libraries for Python](https://googleapis.github.io/google-cloud-python/latest/dataproc/index.html)
9+
[Cloud Client Libraries for Python](https://googleapis.github.io/google-cloud-python/latest/dataproc/index.html)
1010
to programmatically interact with [Dataproc](https://cloud.google.com/dataproc/docs/).
1111

1212
As you follow this walkthrough, you run Python code that calls
@@ -24,7 +24,7 @@ The `submit_job_to_cluster.py file` used in this walkthrough is opened in the
2424
Cloud Shell editor when you launch the walkthrough. You can view
2525
the code as your follow the walkthrough steps.
2626

27-
**For more information**: See [Dataproc&rarr;Use the Python Client Library](https://cloud.google.com/dataproc/docs/tutorials/python-library-example) for
27+
**For more information**: See [Use the Cloud Client Libraries for Python](https://cloud.google.com/dataproc/docs/tutorials/python-library-example) for
2828
an explanation of how the code works.
2929

3030
**To reload this walkthrough:** Run the following command from the
@@ -38,16 +38,21 @@ an explanation of how the code works.
3838

3939
## Prerequisites (1)
4040

41-
1. Create or select a Google Cloud Platform project to use for this tutorial.
42-
* <walkthrough-project-billing-setup permissions=""></walkthrough-project-billing-setup>
43-
44-
1. Click the link below to enable the Dataproc, Compute Engine, and Cloud Storage APIs
45-
in a separate GCP console tab in your browser.
46-
47-
**Note:** After you select your project and enable the APIs, return to this tutorial by clicking
48-
on the **Cloud Shell** tab in your browser.
49-
50-
* [Enable APIs](https://console.cloud.google.com/flows/enableapi?apiid=dataproc,compute_component,storage-component.googleapis.com&redirect=https://console.cloud.google.com)
41+
<walkthrough-watcher-constant key="project_id" value="<project_id>"
42+
></walkthrough-watcher-constant>
43+
44+
1. Create or select a Google Cloud project to use for this
45+
tutorial.
46+
* <walkthrough-project-setup billing="true"></walkthrough-project-setup>
47+
48+
1. Enable the Dataproc, Compute Engine, and Cloud Storage APIs in your
49+
project.
50+
```sh
51+
gcloud services enable dataproc.googleapis.com \
52+
compute.googleapis.com \
53+
storage-component.googleapis.com \
54+
--project={{project_id}}
55+
```
5156

5257
## Prerequisites (2)
5358

0 commit comments

Comments
 (0)