You are viewing documentation for Flux version: 2.2

Version 2.2 of the documentation is no longer actively maintained. The site that you are currently viewing is an archived snapshot. For up-to-date documentation, see the latest version.

Source API reference v1

The GitOps Toolkit Custom Resource Definitions documentation.

Packages:

source.toolkit.fluxcd.io/v1

Package v1 contains API Schema definitions for the source v1 API group

Resource Types:

GitRepository

GitRepository is the Schema for the gitrepositories API.

FieldDescription
apiVersion
string
source.toolkit.fluxcd.io/v1
kind
string
GitRepository
metadata
Kubernetes meta/v1.ObjectMeta
Refer to the Kubernetes API documentation for the fields of the metadata field.
spec
GitRepositorySpec


url
string

URL specifies the Git repository URL, it can be an HTTP/S or SSH address.

secretRef
github.com/fluxcd/pkg/apis/meta.LocalObjectReference
(Optional)

SecretRef specifies the Secret containing authentication credentials for the GitRepository. For HTTPS repositories the Secret must contain ‘username’ and ‘password’ fields for basic auth or ‘bearerToken’ field for token auth. For SSH repositories the Secret must contain ‘identity’ and ‘known_hosts’ fields.

interval
Kubernetes meta/v1.Duration

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.

timeout
Kubernetes meta/v1.Duration
(Optional)

Timeout for Git operations like cloning, defaults to 60s.

ref
GitRepositoryRef
(Optional)

Reference specifies the Git reference to resolve and monitor for changes, defaults to the ‘master’ branch.

verify
GitRepositoryVerification
(Optional)

Verification specifies the configuration to verify the Git commit signature(s).

proxySecretRef
github.com/fluxcd/pkg/apis/meta.LocalObjectReference
(Optional)

ProxySecretRef specifies the Secret containing the proxy configuration to use while communicating with the Git server.

ignore
string
(Optional)

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.

suspend
bool
(Optional)

Suspend tells the controller to suspend the reconciliation of this GitRepository.

recurseSubmodules
bool
(Optional)

RecurseSubmodules enables the initialization of all submodules within the GitRepository as cloned from the URL, using their default settings.

include
[]GitRepositoryInclude
(Optional)

Include specifies a list of GitRepository resources which Artifacts should be included in the Artifact produced for this GitRepository.

status
GitRepositoryStatus

Artifact

(Appears on: GitRepositoryStatus)

Artifact represents the output of a Source reconciliation.

FieldDescription
path
string

Path is the relative file path of the Artifact. It can be used to locate the file in the root of the Artifact storage on the local file system of the controller managing the Source.

url
string

URL is the HTTP address of the Artifact as exposed by the controller managing the Source. It can be used to retrieve the Artifact for consumption, e.g. by another controller applying the Artifact contents.

revision
string

Revision is a human-readable identifier traceable in the origin source system. It can be a Git commit SHA, Git tag, a Helm chart version, etc.

digest
string
(Optional)

Digest is the digest of the file in the form of ‘:’.

lastUpdateTime
Kubernetes meta/v1.Time

LastUpdateTime is the timestamp corresponding to the last update of the Artifact.

size
int64
(Optional)

Size is the number of bytes in the file.

metadata
map[string]string
(Optional)

Metadata holds upstream information such as OCI annotations.

GitRepositoryInclude

(Appears on: GitRepositorySpec, GitRepositoryStatus)

GitRepositoryInclude specifies a local reference to a GitRepository which Artifact (sub-)contents must be included, and where they should be placed.

FieldDescription
repository
github.com/fluxcd/pkg/apis/meta.LocalObjectReference

GitRepositoryRef specifies the GitRepository which Artifact contents must be included.

fromPath
string
(Optional)

FromPath specifies the path to copy contents from, defaults to the root of the Artifact.

toPath
string
(Optional)

ToPath specifies the path to copy contents to, defaults to the name of the GitRepositoryRef.

GitRepositoryRef

(Appears on: GitRepositorySpec)

GitRepositoryRef specifies the Git reference to resolve and checkout.

FieldDescription
branch
string
(Optional)

Branch to check out, defaults to ‘master’ if no other field is defined.

tag
string
(Optional)

Tag to check out, takes precedence over Branch.

semver
string
(Optional)

SemVer tag expression to check out, takes precedence over Tag.

name
string
(Optional)

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”, “refs/pull/420/head”, “refs/merge-requests/1/head”

commit
string
(Optional)

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.

GitRepositorySpec

(Appears on: GitRepository)

GitRepositorySpec specifies the required configuration to produce an Artifact for a Git repository.

FieldDescription
url
string

URL specifies the Git repository URL, it can be an HTTP/S or SSH address.

secretRef
github.com/fluxcd/pkg/apis/meta.LocalObjectReference
(Optional)

SecretRef specifies the Secret containing authentication credentials for the GitRepository. For HTTPS repositories the Secret must contain ‘username’ and ‘password’ fields for basic auth or ‘bearerToken’ field for token auth. For SSH repositories the Secret must contain ‘identity’ and ‘known_hosts’ fields.

interval
Kubernetes meta/v1.Duration

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.

timeout
Kubernetes meta/v1.Duration
(Optional)

Timeout for Git operations like cloning, defaults to 60s.

ref
GitRepositoryRef
(Optional)

Reference specifies the Git reference to resolve and monitor for changes, defaults to the ‘master’ branch.

verify
GitRepositoryVerification
(Optional)

Verification specifies the configuration to verify the Git commit signature(s).

proxySecretRef
github.com/fluxcd/pkg/apis/meta.LocalObjectReference
(Optional)

ProxySecretRef specifies the Secret containing the proxy configuration to use while communicating with the Git server.

ignore
string
(Optional)

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.

suspend
bool
(Optional)

Suspend tells the controller to suspend the reconciliation of this GitRepository.

recurseSubmodules
bool
(Optional)

RecurseSubmodules enables the initialization of all submodules within the GitRepository as cloned from the URL, using their default settings.

include
[]GitRepositoryInclude
(Optional)

Include specifies a list of GitRepository resources which Artifacts should be included in the Artifact produced for this GitRepository.

GitRepositoryStatus

(Appears on: GitRepository)

GitRepositoryStatus records the observed state of a Git repository.

FieldDescription
observedGeneration
int64
(Optional)

ObservedGeneration is the last observed generation of the GitRepository object.

conditions
[]Kubernetes meta/v1.Condition
(Optional)

Conditions holds the conditions for the GitRepository.

artifact
Artifact
(Optional)

Artifact represents the last successful GitRepository reconciliation.

includedArtifacts
[]Artifact
(Optional)

IncludedArtifacts contains a list of the last successfully included Artifacts as instructed by GitRepositorySpec.Include.

observedIgnore
string
(Optional)

ObservedIgnore is the observed exclusion patterns used for constructing the source artifact.

observedRecurseSubmodules
bool
(Optional)

ObservedRecurseSubmodules is the observed resource submodules configuration used to produce the current Artifact.

observedInclude
[]GitRepositoryInclude
(Optional)

ObservedInclude is the observed list of GitRepository resources used to produce the current Artifact.

sourceVerificationMode
GitVerificationMode
(Optional)

SourceVerificationMode is the last used verification mode indicating which Git object(s) have been verified.

ReconcileRequestStatus
github.com/fluxcd/pkg/apis/meta.ReconcileRequestStatus

(Members of ReconcileRequestStatus are embedded into this type.)

GitRepositoryVerification

(Appears on: GitRepositorySpec)

GitRepositoryVerification specifies the Git commit signature verification strategy.

FieldDescription
mode
GitVerificationMode
(Optional)

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.

secretRef
github.com/fluxcd/pkg/apis/meta.LocalObjectReference

SecretRef specifies the Secret containing the public keys of trusted Git authors.

GitVerificationMode (string alias)

(Appears on: GitRepositoryStatus, GitRepositoryVerification)

GitVerificationMode specifies the verification mode for a Git repository.

Source

Source interface must be supported by all API types. Source is the interface that provides generic access to the Artifact and interval. It must be supported by all kinds of the source.toolkit.fluxcd.io API group.

This page was automatically generated with gen-crd-api-reference-docs