Skip to content

Commit

Permalink
Update CUE schemas to Flux v2.3
Browse files Browse the repository at this point in the history
Signed-off-by: Stefan Prodan <[email protected]>
  • Loading branch information
stefanprodan committed May 9, 2024
1 parent 5c77517 commit be3d3c8
Show file tree
Hide file tree
Showing 28 changed files with 1,901 additions and 805 deletions.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Code generated by timoni. DO NOT EDIT.

//timoni:generate timoni vendor crd -f https://github.com/fluxcd/source-controller/releases/download/v1.1.2/source-controller.crds.yaml
//timoni:generate timoni vendor crd -f https://github.com/fluxcd/source-controller/releases/download/v1.3.0/source-controller.crds.yaml

package v1beta1

Expand All @@ -9,16 +9,21 @@ import "strings"
// Bucket is the Schema for the buckets API
#Bucket: {
// APIVersion defines the versioned schema of this representation
// of an object. Servers should convert recognized schemas to the
// latest internal value, and may reject unrecognized values.
// of an object.
// Servers should convert recognized schemas to the latest
// internal value, and
// may reject unrecognized values.
// More info:
// https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
apiVersion: "source.toolkit.fluxcd.io/v1beta1"

// Kind is a string value representing the REST resource this
// object represents. Servers may infer this from the endpoint
// the client submits requests to. Cannot be updated. In
// CamelCase. More info:
// object represents.
// Servers may infer this from the endpoint the client submits
// requests to.
// Cannot be updated.
// In CamelCase.
// More info:
// https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
kind: "Bucket"
metadata!: {
Expand All @@ -44,14 +49,15 @@ import "strings"
#BucketSpec: {
accessFrom?: {
// NamespaceSelectors is the list of namespace selectors to which
// this ACL applies. Items in this list are evaluated using a
// logical OR operation.
// this ACL applies.
// Items in this list are evaluated using a logical OR operation.
namespaceSelectors: [...{
// MatchLabels is a map of {key,value} pairs. A single {key,value}
// in the matchLabels map is equivalent to an element of
// matchExpressions, whose key field is "key", the operator is
// "In", and the values array contains only "value". The
// requirements are ANDed.
// in the matchLabels
// map is equivalent to an element of matchExpressions, whose key
// field is "key", the
// operator is "In", and the values array contains only "value".
// The requirements are ANDed.
matchLabels?: {
[string]: string
}
Expand All @@ -65,9 +71,11 @@ import "strings"
endpoint: string

// Ignore overrides the set of excluded patterns in the
// .sourceignore format (which is the same as .gitignore). If not
// provided, a default will be used, consult the documentation
// for your version to find out what those are.
// .sourceignore format
// (which is the same as .gitignore). If not provided, a default
// will be used,
// consult the documentation for your version to find out what
// those are.
ignore?: string

// Insecure allows connecting to a non-TLS S3 HTTP endpoint.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Code generated by timoni. DO NOT EDIT.

//timoni:generate timoni vendor crd -f https://github.com/fluxcd/source-controller/releases/download/v1.1.2/source-controller.crds.yaml
//timoni:generate timoni vendor crd -f https://github.com/fluxcd/source-controller/releases/download/v1.3.0/source-controller.crds.yaml

package v1beta2

Expand All @@ -9,16 +9,21 @@ import "strings"
// Bucket is the Schema for the buckets API.
#Bucket: {
// APIVersion defines the versioned schema of this representation
// of an object. Servers should convert recognized schemas to the
// latest internal value, and may reject unrecognized values.
// of an object.
// Servers should convert recognized schemas to the latest
// internal value, and
// may reject unrecognized values.
// More info:
// https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
apiVersion: "source.toolkit.fluxcd.io/v1beta2"

// Kind is a string value representing the REST resource this
// object represents. Servers may infer this from the endpoint
// the client submits requests to. Cannot be updated. In
// CamelCase. More info:
// object represents.
// Servers may infer this from the endpoint the client submits
// requests to.
// Cannot be updated.
// In CamelCase.
// More info:
// https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
kind: "Bucket"
metadata!: {
Expand All @@ -37,23 +42,26 @@ import "strings"
}

// BucketSpec specifies the required configuration to produce an
// Artifact for an object storage bucket.
// Artifact for
// an object storage bucket.
spec!: #BucketSpec
}

// BucketSpec specifies the required configuration to produce an
// Artifact for an object storage bucket.
// Artifact for
// an object storage bucket.
#BucketSpec: {
accessFrom?: {
// NamespaceSelectors is the list of namespace selectors to which
// this ACL applies. Items in this list are evaluated using a
// logical OR operation.
// this ACL applies.
// Items in this list are evaluated using a logical OR operation.
namespaceSelectors: [...{
// MatchLabels is a map of {key,value} pairs. A single {key,value}
// in the matchLabels map is equivalent to an element of
// matchExpressions, whose key field is "key", the operator is
// "In", and the values array contains only "value". The
// requirements are ANDed.
// in the matchLabels
// map is equivalent to an element of matchExpressions, whose key
// field is "key", the
// operator is "In", and the values array contains only "value".
// The requirements are ANDed.
matchLabels?: {
[string]: string
}
Expand All @@ -68,21 +76,29 @@ import "strings"
endpoint: string

// Ignore overrides the set of excluded patterns in the
// .sourceignore format (which is the same as .gitignore). If not
// provided, a default will be used, consult the documentation
// for your version to find out what those are.
// .sourceignore format
// (which is the same as .gitignore). If not provided, a default
// will be used,
// consult the documentation for your version to find out what
// those are.
ignore?: string

// Insecure allows connecting to a non-TLS HTTP Endpoint.
insecure?: bool

// Interval at which the Bucket Endpoint is checked for updates.
// This interval is approximate and may be subject to jitter to
// ensure efficient use of resources.
// ensure
// efficient use of resources.
interval: =~"^([0-9]+(\\.[0-9]+)?(ms|s|m|h))+$"

// Provider of the object storage bucket. Defaults to 'generic',
// which expects an S3 (API) compatible object storage.
// Prefix to use for server-side filtering of files in the Bucket.
prefix?: string

// Provider of the object storage bucket.
// Defaults to 'generic', which expects an S3 (API) compatible
// object
// storage.
provider?: "generic" | "aws" | "gcp" | "azure" | *"generic"

// Region of the Endpoint where the BucketName is located in.
Expand All @@ -93,7 +109,8 @@ import "strings"
}

// Suspend tells the controller to suspend the reconciliation of
// this Bucket.
// this
// Bucket.
suspend?: bool

// Timeout for fetch operations, defaults to 60s.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Code generated by timoni. DO NOT EDIT.

//timoni:generate timoni vendor crd -f https://github.com/fluxcd/source-controller/releases/download/v1.1.2/source-controller.crds.yaml
//timoni:generate timoni vendor crd -f https://github.com/fluxcd/source-controller/releases/download/v1.3.0/source-controller.crds.yaml

package v1

Expand All @@ -9,16 +9,21 @@ import "strings"
// GitRepository is the Schema for the gitrepositories API.
#GitRepository: {
// APIVersion defines the versioned schema of this representation
// of an object. Servers should convert recognized schemas to the
// latest internal value, and may reject unrecognized values.
// of an object.
// Servers should convert recognized schemas to the latest
// internal value, and
// may reject unrecognized values.
// More info:
// https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
apiVersion: "source.toolkit.fluxcd.io/v1"

// Kind is a string value representing the REST resource this
// object represents. Servers may infer this from the endpoint
// the client submits requests to. Cannot be updated. In
// CamelCase. More info:
// object represents.
// Servers may infer this from the endpoint the client submits
// requests to.
// Cannot be updated.
// In CamelCase.
// More info:
// https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
kind: "GitRepository"
metadata!: {
Expand All @@ -37,65 +42,80 @@ import "strings"
}

// GitRepositorySpec specifies the required configuration to
// produce an Artifact for a Git repository.
// produce an
// Artifact for a Git repository.
spec!: #GitRepositorySpec
}

// GitRepositorySpec specifies the required configuration to
// produce an Artifact for a Git repository.
// produce an
// Artifact for a Git repository.
#GitRepositorySpec: {
// Ignore overrides the set of excluded patterns in the
// .sourceignore format (which is the same as .gitignore). If not
// provided, a default will be used, consult the documentation
// for your version to find out what those are.
// .sourceignore format
// (which is the same as .gitignore). If not provided, a default
// will be used,
// consult the documentation for your version to find out what
// those are.
ignore?: string

// Include specifies a list of GitRepository resources which
// Artifacts should be included in the Artifact produced for this
// Artifacts
// should be included in the Artifact produced for this
// GitRepository.
include?: [...{
// FromPath specifies the path to copy contents from, defaults to
// the root of the Artifact.
// the root
// of the Artifact.
fromPath?: string
repository: {
// Name of the referent.
name: string
}

// ToPath specifies the path to copy contents to, defaults to the
// name of the GitRepositoryRef.
// name of
// the GitRepositoryRef.
toPath?: string
}]

// Interval at which the GitRepository URL is checked for updates.
// This interval is approximate and may be subject to jitter to
// ensure efficient use of resources.
// ensure
// efficient use of resources.
interval: =~"^([0-9]+(\\.[0-9]+)?(ms|s|m|h))+$"
proxySecretRef?: {
// Name of the referent.
name: string
}

// RecurseSubmodules enables the initialization of all submodules
// within the GitRepository as cloned from the URL, using their
// default settings.
// within
// the GitRepository as cloned from the URL, using their default
// settings.
recurseSubmodules?: bool

// Reference specifies the Git reference to resolve and monitor
// for changes, defaults to the 'master' branch.
// for
// changes, defaults to the 'master' branch.
ref?: {
// Branch to check out, defaults to 'master' if no other field is
// defined.
branch?: string

// Commit SHA to check out, takes precedence over all reference
// fields.
//
//
// This can be combined with Branch to shallow clone the branch,
// in which the commit is expected to exist.
// in which
// the commit is expected to exist.
commit?: string

// Name of the reference to check out; takes precedence over
// Branch, Tag and SemVer.
//
//
// It must be a valid Git reference:
// https://git-scm.com/docs/git-check-ref-format#_description
// Examples: "refs/heads/main", "refs/tags/v0.1.0",
Expand All @@ -114,7 +134,8 @@ import "strings"
}

// Suspend tells the controller to suspend the reconciliation of
// this GitRepository.
// this
// GitRepository.
suspend?: bool

// Timeout for Git operations like cloning, defaults to 60s.
Expand All @@ -125,13 +146,17 @@ import "strings"
url: =~"^(http|https|ssh)://.*$"

// Verification specifies the configuration to verify the Git
// commit signature(s).
// commit
// signature(s).
verify?: {
// Mode specifies which Git object(s) should be verified.
//
//
// The variants "head" and "HEAD" both imply the same thing, i.e.
// verify the commit that the HEAD of the Git repository points
// to. The variant "head" solely exists to ensure backwards
// compatibility.
// verify
// the commit that the HEAD of the Git repository points to. The
// variant
// "head" solely exists to ensure backwards compatibility.
mode?: "head" | "HEAD" | "Tag" | "TagAndHEAD" | *"HEAD"
secretRef: {
// Name of the referent.
Expand Down
Loading

0 comments on commit be3d3c8

Please sign in to comment.