Skip to content

Commit c868eaf

Browse files
authored
Merge pull request #3752 from saschagrunert/acl
Remove ACL ownership change on release publish
2 parents e75995d + 908e806 commit c868eaf

File tree

1 file changed

+0
-19
lines changed

1 file changed

+0
-19
lines changed

pkg/release/publish.go

-19
Original file line numberDiff line numberDiff line change
@@ -371,25 +371,6 @@ func (p *Publisher) PublishToGcs(
371371

372372
var content string
373373
if !privateBucket {
374-
// New Kubernetes infra buckets, like k8s-staging-kubernetes, have a
375-
// bucket-only ACL policy set, which means attempting to set the ACL on
376-
// an object will fail. We should skip this ACL change in those
377-
// instances, as new buckets already default to being publicly
378-
// readable.
379-
//
380-
// Ref:
381-
// - https://cloud.google.com/storage/docs/bucket-policy-only
382-
// - https://github.com/kubernetes/release/issues/904
383-
if !strings.HasPrefix(markerPath, object.GcsPrefix+"k8s-") {
384-
aclOutput, err := p.client.GSUtilOutput(
385-
"acl", "ch", "-R", "-g", "all:R", publishFileDst,
386-
)
387-
if err != nil {
388-
return fmt.Errorf("change %s permissions: %w", publishFileDst, err)
389-
}
390-
logrus.Infof("Making uploaded version file public: %s", aclOutput)
391-
}
392-
393374
// If public, validate public link
394375
response, err := p.client.GetURLResponse(publicLink)
395376
if err != nil {

0 commit comments

Comments
 (0)