diff --git a/tools/bots/bot_utils.py b/tools/bots/bot_utils.py index 5bd718bddd4..58f136dbe1e 100755 --- a/tools/bots/bot_utils.py +++ b/tools/bots/bot_utils.py @@ -227,7 +227,6 @@ class GSUtil(object): local_path, remote_path, recursive=False, - public=False, multithread=False): assert remote_path.startswith('gs://') @@ -235,8 +234,6 @@ class GSUtil(object): args = ['-m', 'cp'] else: args = ['cp'] - if public: - args += ['-a', 'public-read'] if recursive: args += ['-R'] args += [local_path, remote_path] diff --git a/tools/bots/dart_sdk.py b/tools/bots/dart_sdk.py index 0451f7b23ea..d14f3ce1119 100755 --- a/tools/bots/dart_sdk.py +++ b/tools/bots/dart_sdk.py @@ -117,7 +117,6 @@ def UploadDartdocApiDocs(dir_name): dir_name, dartdocs_destination_gcsdir, recursive=True, - public=True, multithread=True) @@ -185,7 +184,7 @@ def GuessExtension(binary): def DartArchiveFile(local_path, remote_path, checksum_files=False): gsutil = bot_utils.GSUtil() - gsutil.upload(local_path, remote_path, public=True) + gsutil.upload(local_path, remote_path) if checksum_files: # 'local_path' may have a different filename than 'remote_path'. So we need # to make sure the *.md5sum file contains the correct name. @@ -194,10 +193,10 @@ def DartArchiveFile(local_path, remote_path, checksum_files=False): mangled_filename = remote_path[remote_path.rfind('/') + 1:] local_md5sum = bot_utils.CreateMD5ChecksumFile(local_path, mangled_filename) - gsutil.upload(local_md5sum, remote_path + '.md5sum', public=True) + gsutil.upload(local_md5sum, remote_path + '.md5sum') local_sha256 = bot_utils.CreateSha256ChecksumFile( local_path, mangled_filename) - gsutil.upload(local_sha256, remote_path + '.sha256sum', public=True) + gsutil.upload(local_sha256, remote_path + '.sha256sum') def Run(command, env=None): diff --git a/tools/linux_dist_support/upload_debian_packages.py b/tools/linux_dist_support/upload_debian_packages.py index d2f7151760b..ab3c9118127 100755 --- a/tools/linux_dist_support/upload_debian_packages.py +++ b/tools/linux_dist_support/upload_debian_packages.py @@ -22,7 +22,7 @@ def ArchiveArtifacts(tarfile, builddir, channel): remote_tarfile = '/'.join( [namer.src_directory(revision), os.path.basename(tarfile)]) - gsutil.upload(tarfile, remote_tarfile, public=True) + gsutil.upload(tarfile, remote_tarfile) # Archive all files except the tar file to the linux packages dir for entry in os.listdir(builddir): full_path = os.path.join(builddir, entry) @@ -31,7 +31,7 @@ def ArchiveArtifacts(tarfile, builddir, channel): if full_path != tarfile: package_dir = namer.linux_packages_directory(revision) remote_file = '/'.join([package_dir, os.path.basename(entry)]) - gsutil.upload(full_path, remote_file, public=True) + gsutil.upload(full_path, remote_file) if __name__ == '__main__': diff --git a/tools/promote.py b/tools/promote.py index 966b735e8a0..4d32d19a3ef 100755 --- a/tools/promote.py +++ b/tools/promote.py @@ -152,30 +152,30 @@ def _PromoteDartArchiveBuild(channel, source_channel, revision): remove_gs_directory(to_loc) has_signed = exists(from_loc) if has_signed: - Gsutil(['-m', 'cp', '-a', 'public-read', '-R', from_loc, to_loc]) + Gsutil(['-m', 'cp', '-R', from_loc, to_loc]) # Because gsutil copies differently to existing directories, we need # to use the base directory for the next recursive copy. to_loc = release_namer.base_directory(to_revision) # Copy the unsigned sdk directory without clobbering signed files. from_loc = raw_namer.sdk_directory(revision) - Gsutil(['-m', 'cp', '-n', '-a', 'public-read', '-R', from_loc, to_loc]) + Gsutil(['-m', 'cp', '-n', '-R', from_loc, to_loc]) # Copy api-docs zipfile. from_loc = raw_namer.apidocs_zipfilepath(revision) to_loc = release_namer.apidocs_zipfilepath(to_revision) - Gsutil(['-m', 'cp', '-a', 'public-read', from_loc, to_loc]) + Gsutil(['-m', 'cp', from_loc, to_loc]) # Copy linux deb and src packages. from_loc = raw_namer.linux_packages_directory(revision) to_loc = release_namer.linux_packages_directory(to_revision) remove_gs_directory(to_loc) - Gsutil(['-m', 'cp', '-a', 'public-read', '-R', from_loc, to_loc]) + Gsutil(['-m', 'cp', '-R', from_loc, to_loc]) # Copy VERSION file. from_loc = raw_namer.version_filepath(revision) to_loc = release_namer.version_filepath(to_revision) - Gsutil(['cp', '-a', 'public-read', from_loc, to_loc]) + Gsutil(['cp', from_loc, to_loc]) promote(revision) promote('latest')