= Gitops Trait

// Start of autogenerated code - DO NOT EDIT! (badges)
// End of autogenerated code - DO NOT EDIT! (badges)
// Start of autogenerated code - DO NOT EDIT! (description)
The GitOps Trait is used to configure the repository where you want to push a GitOps Kustomize overlay configuration of the Integration or Pipe built.
If the trait is enabled but no pull configuration is provided, then, the operator will use the values stored in Integration `.spec.git` field used
to pull the project. When used with a Pipe, the `url` and `secret` parameters are required as Pipes do not have a `.spec.git` fallback.


This trait is available in the following profiles: **Kubernetes, Knative, OpenShift**.

// End of autogenerated code - DO NOT EDIT! (description)
// Start of autogenerated code - DO NOT EDIT! (configuration)
== Configuration

Trait properties can be specified when running any integration with the CLI:
[source,console]
----
$ kamel run --trait gitops.[key]=[value] --trait gitops.[key2]=[value2] integration.yaml
----
The following configuration options are available:

[cols="2m,1m,5a"]
|===
|Property | Type | Description

| gitops.enabled
| bool
| Can be used to enable or disable a trait. All traits share this common property.

| gitops.url
| string
| the URL of the repository where the project is stored.

| gitops.secret
| string
| the Kubernetes secret where the Git token is stored. The operator will pick up the first secret key only, whichever the name it is.

| gitops.branch
| string
| the git branch to check out.

| gitops.tag
| string
| the git tag to check out.

| gitops.commit
| string
| the git commit (full SHA) to check out.

| gitops.branch-push
| string
| the git branch to push to. If omitted, the operator will push to a new branch named as `cicd/release-candidate-<datetime>`.

| gitops.overlays
| []string
| a list of overlays to provide (default {"dev","stag","prod"}).

| gitops.overwrite-overlay
| bool
| a flag (default, false) to overwrite any existing overlay.

| gitops.integration-directory
| string
| The root path where to store Kustomize overlays (default `integrations`).

| gitops.committed-name
| string
| The name used to commit the GitOps changes (default `Camel K Operator`).

| gitops.committed-email
| string
| The email used to commit the GitOps changes (default `camel-k-operator@apache.org`).

|===

// End of autogenerated code - DO NOT EDIT! (configuration)
