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

Added support for licenses #59

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

BrettPowell
Copy link

This adds an optional parameter for licenses to be added to dataproc
images.

This parameter supports the gcloud syntax for passing in licenses of
a list of licenses separates by commas inside of a string, with an
optional space.

This adds an optional parameter for licenses to be added to dataproc
images.

This parameter supports the gcloud syntax for passing in licenses of
a list of licenses seperates by commas inside of a string, with an
optional space.
@medb
Copy link
Contributor

medb commented Sep 8, 2021

May you explain what is use case for the extra licenses or even overriding licenses?

@medb medb requested a review from functicons September 8, 2021 14:57
@functicons
Copy link
Contributor

+1, this requires a product decision, we need to understand the use case first. In my opinion, we might not want customers to apply other licenses other than the default Dataproc license.

@BrettPowell
Copy link
Author

To clarify I’m not asking for anything in GCP to change. We just want the ability to add to the list of licenses through this script. This behavior does not effect applied licenses from the original image.

The functionality of adding licenses to an image is something we already do in an additional automation step after building the Dataproc image.

The use case: We utilize licenses as a way to validate that our image is the base image for all our customer's images.

@@ -88,7 +88,7 @@
fi

echo 'Creating custom image.'
gcloud compute images create my-image --project=my-project --source-disk-zone=us-west1-a --source-disk=my-image-install --storage-location=us-east1 --family=debian9
gcloud compute images create my-image --project=my-project --source-disk-zone=us-west1-a --source-disk=my-image-install --storage-location=us-east1 --family=debian9 --licenses='https://www.googleapis.com/compute/v1/projects/my-project/global/licenses/my-license'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The family needs to be updated here. We're up to 12 on the debian versions, and so support for 9 has slipped into the bit bucket with oldoldoldstable

@@ -122,7 +122,8 @@ def test_generate_shell_script(self):
'project_id': 'my-project',
'storage_location': 'us-east1',
'shutdown_timer_in_sec': 500,
'base_image_family': 'projects/my-dataproc-project/global/images/family/debian-10'
'base_image_family': 'projects/my-dataproc-project/global/images/family/debian-10',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please let's d use 12 if we can here. 10 will be slipping into the bit bucket with the impending release of 13, trixie, which is already in testing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants