Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding machine-type parameters to create_cluster() function #1126

Closed
claudiadast opened this issue Sep 19, 2017 · 3 comments
Closed

Adding machine-type parameters to create_cluster() function #1126

claudiadast opened this issue Sep 19, 2017 · 3 comments
Labels

Comments

@claudiadast
Copy link

In which file did you encounter the issue?

python-docs-samples/dataproc/submit_job_to_cluster.py

Describe the issue

Is it possible to add the master machine type and worker machine type args in the following function?

# [START create_cluster]
def create_cluster(dataproc, project, zone, region, cluster_name):
    print('Creating cluster...')
    zone_uri = \
        'https://www.googleapis.com/compute/v1/projects/{}/zones/{}'.format(
            project, zone)
    cluster_data = {
        'projectId': project,
        'clusterName': cluster_name,
        'config': {
            'gceClusterConfig': {
                'zoneUri': zone_uri
            }
        }
    }
    result = dataproc.projects().regions().clusters().create(
        projectId=project,
        region=region,
        body=cluster_data).execute()
    return result
# [END create_cluster]
@theacodes
Copy link
Contributor

@waprin can you take a look?

@waprin
Copy link
Contributor

waprin commented Sep 20, 2017

Will take look

@engelke
Copy link
Contributor

engelke commented Dec 5, 2018

Handled by PR #1203.

@engelke engelke closed this as completed Dec 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants