I have researched a lot and unable to come up with a solution for this. Here is the code i am using to make all the files public in GCP:
def make_blob_public(bucket_name, blob_name):
"""Makes a blob publicly accessible."""
storage_client = storage.Client()
bucket = storage_client.get_bucket(bucket_name)
blob = bucket.blob(blob_name)
blob.make_public()
The above method works but when i write blob.make_private() to make all files private i get the error: AttributeError: 'Blob' object has no attribute 'make_private'
At this link:
https://googlecloudplatform.github.io/google-cloud-python/latest/storage/blobs.html
i can find both make_public() and make_private() but only make_public() works.