Skip to content
CRD Reference

CRD Reference

Both namespaced resources use apiVersion: sourcegateway.dev/v1alpha1 and share spec.authorization.rules. A rule has a unique nonempty name, one or more supported operations, and a nonempty CEL allow expression (maximum 4 KiB); there are at most 32 rules.

GitRepository

FieldMeaning
spec.upstream.urlGit smart HTTP repository URL. HTTPS is required unless the process permits that exact HTTP origin.
spec.upstream.credentialName in runtime credentials.gitRepository, permitted for this namespace.
spec.mirror.refreshIntervalPositive periodic mirror refresh interval.
spec.mirror.maxStalenessPositive maximum age that may serve reads; gateway pushes update the mirror immediately.
spec.authorization.rulesRules using git.read and/or git.push.

status.path is /git/<namespace>/<name>.git.

ObjectStorageBucket

FieldMeaning
spec.backend.providers3 or gcs.
spec.backend.endpointOptional object storage API base URL. Its origin must match the selected credential’s effective origin. HTTPS is required unless the process permits that exact HTTP origin.
spec.backend.regionRequired for S3 and omitted for GCS.
spec.backend.bucketAuthoritative provider bucket name.
spec.backend.credentialName in runtime credentials.objectStorageBucket, permitted for this namespace.
spec.cache.capacityPositive per-source cache maximum, no greater than the global maximum.
spec.cache.ttlPositive retention duration for cached reads; gateway writes refresh or evict affected entries.
spec.authorization.rulesRules using the bucket.* and object.* operations.

status.bucketName is the stable S3-compatible name clients use at the gateway; do not derive or replace it with the upstream bucket name.

Shared status

status.observedGeneration identifies the reconciled generation, status.policyRevision identifies the compiled policy, and status.conditions contains PolicyReady, CredentialsReady, UpstreamReady, and Ready. A source is served only when Ready=True for its current generation.