Files
cozystack/packages/apps
Mattia Eleuteri 21fd2b7b69 feat(bucket): add publicRead to serve a bucket without credentials
A bucket cannot serve its objects without a signature: every
BucketAccess issues a key, and the keys grant neither WriteAcp nor
PutBucketPolicy, so a tenant cannot open the bucket themselves with
put-bucket-acl. Static assets then need a proxy, presigned URLs or
an operator running weed shell by hand, which no reconcile tracks
and which outlives the bucket.

publicRead renders one more BucketAccess on a new -public access
class whose accessPolicy is public-read. The COSI driver handles that
policy by adding Read:<bucket> to the gateway's anonymous identity
and removing only that action on revoke, so deleting the bucket or
turning the flag off closes it again without touching other public
buckets. Anonymous callers can read objects but cannot list the
bucket or write to it.

The access is named <bucket>-public-read, the name a user called
public-read would take, so that combination fails to render instead
of fighting over one BucketAccess.

Assisted-by: LLM
Signed-off-by: Mattia Eleuteri <mattia@hidora.io>
2026-11-13 13:02:02 +03:00
..
2025-08-07 14:07:05 +03:00

How to test packages local

cd packages/core/installer
make image-cozystack REGISTRY=YOUR_CUSTOM_REGISTRY
make apply
kubectl delete po -l app=source-controller -n cozy-fluxcd