github.com/argoproj-labs/argocd-operator@v0.10.0/docs/reference/argocd.md (about)

     1  # ArgoCD
     2  
     3  The `ArgoCD` resource is a Kubernetes Custom Resource (CRD) that describes the desired state for a given Argo CD
     4  cluster and allows for the configuration of the components that make up an Argo CD cluster.
     5  
     6  When the Argo CD Operator sees a new ArgoCD resource, the components are provisioned using Kubernetes resources and
     7  managed by the operator. When something changes on an existing ArgoCD resource, the operator works to reconfigure the
     8  cluster to ensure the actual state of the cluster matches the desired state.
     9  
    10  The ArgoCD Custom Resource consists of the following properties.
    11  
    12  Name | Default | Description
    13  --- | --- | ---
    14  [**ApplicationInstanceLabelKey**](#application-instance-label-key) | `mycompany.com/appname` |  The metadata.label key name where Argo CD injects the app name as a tracking label.
    15  [**ApplicationSet**](#applicationset-controller-options) | [Object] | ApplicationSet controller configuration options.
    16  [**ConfigManagementPlugins**](#config-management-plugins) | [Empty] | Configuration to add a config management plugin.
    17  [**Controller**](#controller-options) | [Object] | Argo CD Application Controller options.
    18  [**DisableAdmin**](#disable-admin) | `false` | Disable the admin user.
    19  [**ExtraConfig**](#extra-config) | [Empty] | A catch-all mechanism to populate the argocd-cm configmap.
    20  [**GATrackingID**](#ga-tracking-id) | [Empty] | The google analytics tracking ID to use.
    21  [**GAAnonymizeUsers**](#ga-anonymize-users) | `false` | Enable hashed usernames sent to google analytics.
    22  [**HA**](#ha-options) | [Object] | High Availability options.
    23  [**HelpChatURL**](#help-chat-url) | `https://mycorp.slack.com/argo-cd` | URL for getting chat help, this will typically be your Slack channel for support.
    24  [**HelpChatText**](#help-chat-text) | `Chat now!` | The text for getting chat help.
    25  [**Image**](#image) | `argoproj/argocd` | The container image for all Argo CD components. This overrides the `ARGOCD_IMAGE` environment variable.
    26  [**Import**](#import-options) | [Object] | Import configuration options.
    27  [**Ingress**](#ingress-options) | [Object] | Ingress configuration options.
    28  [**InitialRepositories**](#initial-repositories) | [Empty] | Initial git repositories to configure Argo CD to use upon creation of the cluster.
    29  [**Notifications**](#notifications-controller-options) | [Object] | Notifications controller configuration options.
    30  [**RepositoryCredentials**](#repository-credentials) | [Empty] | Git repository credential templates to configure Argo CD to use upon creation of the cluster.
    31  [**InitialSSHKnownHosts**](#initial-ssh-known-hosts) | [Default Argo CD Known Hosts] | Initial SSH Known Hosts for Argo CD to use upon creation of the cluster.
    32  [**KustomizeBuildOptions**](#kustomize-build-options) | [Empty] | The build options/parameters to use with `kustomize build`.
    33  [**OIDCConfig**](#oidc-config) | [Empty] | The OIDC configuration as an alternative to Dex.
    34  [**NodePlacement**](#nodeplacement-option) | [Empty] | The NodePlacement configuration can be used to add nodeSelector and tolerations.
    35  [**Prometheus**](#prometheus-options) | [Object] | Prometheus configuration options.
    36  [**RBAC**](#rbac-options) | [Object] | RBAC configuration options.
    37  [**Redis**](#redis-options) | [Object] | Redis configuration options.
    38  [**ResourceHealthChecks**](#resource-customizations) | [Empty] | Customizes resource health check behavior.
    39  [**ResourceIgnoreDifferences**](#resource-customizations) | [Empty] | Customizes resource ignore difference behavior.
    40  [**ResourceActions**](#resource-customizations) | [Empty] | Customizes resource action behavior.
    41  [**ResourceExclusions**](#resource-exclusions) | [Empty] | The configuration to completely ignore entire classes of resource group/kinds.
    42  [**ResourceInclusions**](#resource-inclusions) | [Empty] | The configuration to configure which resource group/kinds are applied.
    43  [**ResourceTrackingMethod**](#resource-tracking-method) | `label` | The resource tracking method Argo CD should use.
    44  [**Server**](#server-options) | [Object] | Argo CD Server configuration options.
    45  [**SSO**](#single-sign-on-options) | [Object] | Single sign-on options.
    46  [**StatusBadgeEnabled**](#status-badge-enabled) | `true` | Enable application status badge feature.
    47  [**TLS**](#tls-options) | [Object] | TLS configuration options.
    48  [**UsersAnonymousEnabled**](#users-anonymous-enabled) | `true` | Enable anonymous user access.
    49  [**Version**](#version) | v2.4.0 (SHA) | The tag to use with the container image for all Argo CD components.
    50  [**Banner**](#banner) | [Object] | Add a UI banner message.
    51  
    52  ## Application Instance Label Key
    53  
    54  The metadata.label key name where Argo CD injects the app name as a tracking label (optional). Tracking labels are used to determine which resources need to be deleted when pruning. If omitted, Argo CD injects the app name into the label: 'app.kubernetes.io/instance'
    55  
    56  This property maps directly to the `application.instanceLabelKey` field in the `argocd-cm` ConfigMap.
    57  
    58  ### Application Instance Label Key Example
    59  
    60  The following example sets the default value in the `argocd-cm` ConfigMap using the `ApplicationInstanceLabelKey` property on the `ArgoCD` resource.
    61  
    62  ``` yaml
    63  apiVersion: argoproj.io/v1alpha1
    64  kind: ArgoCD
    65  metadata:
    66    name: example-argocd
    67    labels:
    68      example: application-instance-label-key
    69  spec:
    70    applicationInstanceLabelKey: mycompany.com/appname
    71  ```
    72  
    73  ## ApplicationSet Controller Options
    74  
    75  The following properties are available for configuring the ApplicationSet controller component.
    76  
    77  Name | Default | Description
    78  --- | --- | ---
    79  Env | [Empty] | Environment to set for the applicationSet controller workloads
    80  [ExtraCommandArgs](#add-command-arguments-to-applicationsets-controller) | [Empty] | Extra Command arguments allows users to pass command line arguments to applicationSet workload. They get added to default command line arguments provided by the operator.
    81  Image | `quay.io/argoproj/argocd-applicationset` | The container image for the ApplicationSet controller. This overrides the `ARGOCD_APPLICATIONSET_IMAGE` environment variable.
    82  Version | *(recent ApplicationSet version)* | The tag to use with the ApplicationSet container image.
    83  Resources | [Empty] | The container compute resources.
    84  LogLevel | info | The log level to be used by the ArgoCD Application Controller component. Valid options are debug, info, error, and warn.
    85  LogFormat | text | The log format to be used by the ArgoCD Application Controller component. Valid options are text or json.
    86  ParallelismLimit | 10 | The kubectl parallelism limit to set for the controller (`--kubectl-parallelism-limit` flag)
    87  SCMRootCAConfigMap (#add-tls-certificate-for-gitlab-scm-provider-to-applicationsets-controller) | [Empty] | The name of the config map that stores the Gitlab SCM Provider's TLS certificate which will be mounted on the ApplicationSet Controller at `"/app/tls/scm/cert"` path.
    88  Enabled|true|Flag to enable/disable the ApplicationSet Controller during ArgoCD installation.
    89  SourceNamespaces|[Empty]|List of namespaces other than control-plane namespace where appsets can be created.
    90  SCMProviders|[Empty]|List of allowed Source Code Manager (SCM) providers URL.
    91  
    92  ### ApplicationSet Controller Example
    93  
    94  The following example shows all properties set to the default values.
    95  
    96  ``` yaml
    97  apiVersion: argoproj.io/v1alpha1
    98  kind: ArgoCD
    99  metadata:
   100    name: example-argocd
   101    labels:
   102      example: applicationset
   103  spec:
   104    applicationSet: {}
   105  ```
   106  
   107  ### Add Command Arguments to ApplicationSets Controller
   108  
   109  Below example shows how a user can add command arguments to the ApplicationSet controller.
   110  
   111  ``` yaml
   112  apiVersion: argoproj.io/v1alpha1
   113  kind: ArgoCD
   114  metadata:
   115    name: example-argocd
   116    labels:
   117      example: applicationset
   118  spec:
   119    applicationSet:
   120      extraCommandArgs:
   121        - --foo
   122        - bar
   123  ```
   124  
   125  ### Add Self signed TLS Certificate for Gitlab SCM Provider to ApplicationSets Controller
   126  
   127  ApplicationSetController added a new option `--scm-root-ca-path` and expects the self-signed TLS certificate to be mounted on the path specified and to be used for Gitlab SCM Provider and Gitlab Pull Request Provider. To set this option, you can store the certificate in the config map and specify the config map name using `spec.applicationSet.SCMRootCAConfigMap` in ArgoCD CR. When the parameter `spec.applicationSet.SCMRootCAConfigMap` is set in ArgoCD CR, the operator checks for ConfigMap in the same namespace as the ArgoCD instance and mounts the Certificate stored in ConfigMap to ApplicationSet Controller pods at the path `/app/tls/scm/cert`.
   128  
   129  Below example shows how a user can add scmRootCaPath to the ApplicationSet controller.
   130  ```yaml
   131  apiVersion: argoproj.io/v1alpha1
   132  kind: ArgoCD
   133  metadata:
   134    name: example-argocd
   135    labels:
   136      example: applicationset
   137  spec:
   138    applicationSet:
   139      SCMRootCAConfigMap: example-gitlab-scm-tls-cert
   140  ```
   141  
   142  ## Config Management Plugins
   143  
   144  Configuration to add a config management plugin. This property maps directly to the `configManagementPlugins` field in the `argocd-cm` ConfigMap.
   145  
   146  ### Config Management Plugins Example
   147  
   148  The following example sets a value in the `argocd-cm` ConfigMap using the `ConfigManagementPlugins` property on the `ArgoCD` resource.
   149  
   150  ``` yaml
   151  apiVersion: argoproj.io/v1alpha1
   152  kind: ArgoCD
   153  metadata:
   154    name: example-argocd
   155    labels:
   156      example: config-management-plugins
   157  spec:
   158    configManagementPlugins: |
   159      - name: kasane
   160        init:
   161          command: [kasane, update]
   162        generate:
   163          command: [kasane, show]
   164  ```
   165  
   166  ## Controller Options
   167  
   168  The following properties are available for configuring the Argo CD Application Controller component.
   169  
   170  Name | Default | Description | Validation Criteira |
   171  --- | --- | --- | ---
   172  Processors.Operation | 10 | The number of operation processors. | |
   173  Processors.Status | 20 | The number of status processors. | |
   174  Resources | [Empty] | The container compute resources. | |
   175  LogLevel | info | The log level to be used by the ArgoCD Application Controller component. | Valid options are debug, info, error, and warn. |
   176  AppSync | 3m | AppSync is used to control the sync frequency of ArgoCD Applications | |
   177  Sharding.enabled | false | Whether to enable sharding on the ArgoCD Application Controller component. Useful when managing a large number of clusters to relieve memory pressure on the controller component. | |
   178  Sharding.replicas | 1 | The number of replicas that will be used to support sharding of the ArgoCD Application Controller. | Must be greater than 0 |
   179  Env | [Empty] | Environment to set for the application controller workloads | |
   180  Sharding.dynamicScalingEnabled | true | Whether to enable dynamic scaling of the ArgoCD Application Controller component. This will ignore the configuration of `Sharding.enabled` and `Sharding.replicas` | |
   181  Sharding.minShards | 1 | The minimum number of replicas of the ArgoCD Application Controller component. | Must be greater than 0 |
   182  Sharding.maxShards | 1 | The maximum number of replicas of the ArgoCD Application Controller component. | Must be greater than `Sharding.minShards` |
   183  Sharding.clustersPerShard | 1 | The number of clusters that need to be handles by each shard. In case the replica count has reached the maxShards, the shards will manage more than one cluster. | Must be greater than 0 |
   184  
   185  ### Controller Example
   186  
   187  The following example shows all properties set to the default values.
   188  
   189  ``` yaml
   190  apiVersion: argoproj.io/v1alpha1
   191  kind: ArgoCD
   192  metadata:
   193    name: example-argocd
   194    labels:
   195      example: controller
   196  spec:
   197    controller:
   198      processors:
   199        operation: 10
   200        status: 20
   201      resources: {}
   202  ```
   203  
   204  The following example shows how to set command line parameters using the env variable
   205  
   206  ``` yaml
   207  apiVersion: argoproj.io/v1alpha1
   208  kind: ArgoCD
   209  metadata:
   210    name: example-argocd
   211    labels:
   212      example: controller
   213  spec:
   214    controller:
   215      env:
   216      - name: ARGOCD_APPLICATION_CONTROLLER_REPO_SERVER_TIMEOUT_SECONDS
   217        value: '120'
   218  ```
   219  
   220  The following example shows how to set multiple replicas of Argo CD Application Controller. This example will scale up/down the Argo CD Application Controller based on the parameter clustersPerShard. The number of replicas will be set between minShards and maxShards.
   221  
   222  ```yaml
   223  apiVersion: argoproj.io/v1alpha1
   224  kind: ArgoCD
   225  metadata:
   226    name: example-argocd
   227    labels:
   228      example: controller
   229  spec:
   230    controller:
   231      sharding:
   232        dynamicScalingEnabled: true
   233        minShards: 2
   234        maxShards: 5
   235        clustersPerShard: 10
   236  ```
   237  
   238  !!! note
   239      In case the number of replicas required is less than the minShards the number of replicas will be set as minShards. Similarly, if the required number of replicas exceeds maxShards, the replica count will be set as maxShards.
   240  
   241  The following example shows how to enable dynamic scaling of the ArgoCD Application Controller component.
   242  
   243  ```yaml
   244  apiVersion: argoproj.io/v1alpha1
   245  kind: ArgoCD
   246  metadata:
   247    name: example-argocd
   248    labels:
   249      example: controller
   250  spec:
   251    controller:
   252      sharding:
   253        enabled: true
   254        replicas: 5
   255  ```
   256  
   257  ## Disable Admin
   258  
   259  Disable the admin user. This property maps directly to the `admin.enabled` field in the `argocd-cm` ConfigMap.
   260  
   261  ### Disable Admin Example
   262  
   263  The following example disables the admin user using the `DisableAdmin` property on the `ArgoCD` resource.
   264  
   265  ``` yaml
   266  apiVersion: argoproj.io/v1alpha1
   267  kind: ArgoCD
   268  metadata:
   269    name: example-argocd
   270    labels:
   271      example: disable-admin
   272  spec:
   273    disableAdmin: true
   274  ```
   275  
   276  ## Extra Config
   277  
   278  This is a generic mechanism to add new or otherwise-unsupported
   279  features to the argocd-cm configmap.  Manual edits to the argocd-cm
   280  configmap will otherwise be automatically reverted.
   281  
   282  This defaults to empty.
   283  
   284  ## Extra Config Example
   285  
   286  ``` yaml
   287  apiVersion: argoproj.io/v1alpha1
   288  kind: ArgoCD
   289  metadata:
   290    name: example-argocd
   291  spec:
   292    extraConfig:
   293      "accounts.argocd-devops": "apiKey"
   294      "ping": "pong" // The same entry is reflected in Argo CD Configmap.
   295  ```
   296  
   297  ## GA Tracking ID
   298  
   299  The google analytics tracking ID to use. This property maps directly to the `ga.trackingid` field in the `argocd-cm` ConfigMap.
   300  
   301  ### GA Tracking ID Example
   302  
   303  The following example sets a value in the `argocd-cm` ConfigMap using the `GATrackingID` property on the `ArgoCD` resource.
   304  
   305  ``` yaml
   306  apiVersion: argoproj.io/v1alpha1
   307  kind: ArgoCD
   308  metadata:
   309    name: example-argocd
   310    labels:
   311      example: ga-tracking-id
   312  spec:
   313    gaTrackingID: UA-12345-1
   314  ```
   315  
   316  ## GA Anonymize Users
   317  
   318  Enable hashed usernames sent to google analytics. This property maps directly to the `ga.anonymizeusers` field in the `argocd-cm` ConfigMap.
   319  
   320  ### GA Anonymize Users Example
   321  
   322  The following example sets a value in the `argocd-cm` ConfigMap using the `GAAnonymizeUsers` property on the `ArgoCD` resource.
   323  
   324  ``` yaml
   325  apiVersion: argoproj.io/v1alpha1
   326  kind: ArgoCD
   327  metadata:
   328    name: example-argocd
   329    labels:
   330      example: ga-anonymize-users
   331  spec:
   332    gaAnonymizeUsers: true
   333  ```
   334  
   335  ## HA Options
   336  
   337  The following properties are available for configuring High Availability for the Argo CD cluster.
   338  
   339  Name | Default | Description
   340  --- | --- | ---
   341  Enabled | `false` | Toggle High Availability support globally for Argo CD.
   342  RedisProxyImage | `haproxy` | The Redis HAProxy container image. This overrides the `ARGOCD_REDIS_HA_PROXY_IMAGE`environment variable.
   343  RedisProxyVersion | `2.0.4` | The tag to use for the Redis HAProxy container image.
   344  Resources | [Empty] | The container compute resources.
   345  
   346  ### HA Example
   347  
   348  The following example shows how to enable HA mode globally.
   349  
   350  ``` yaml
   351  apiVersion: argoproj.io/v1alpha1
   352  kind: ArgoCD
   353  metadata:
   354    name: example-argocd
   355    labels:
   356      example: ha
   357  spec:
   358    ha:
   359      enabled: true
   360      redisProxyImage: haproxy
   361      redisProxyVersion: "2.0.4"
   362  ```
   363  
   364  ## Help Chat URL
   365  
   366  URL for getting chat help, this will typically be your Slack channel for support. This property maps directly to the `help.chatUrl` field in the `argocd-cm` ConfigMap.
   367  
   368  ### Help Chat URL Example
   369  
   370  The following example sets the default value in the `argocd-cm` ConfigMap using the `HelpChatURL` property on the `ArgoCD` resource.
   371  
   372  ``` yaml
   373  apiVersion: argoproj.io/v1alpha1
   374  kind: ArgoCD
   375  metadata:
   376    name: example-argocd
   377    labels:
   378      example: help-chat-url
   379  spec:
   380    helpChatURL: https://mycorp.slack.com/argo-cd
   381  ```
   382  
   383  ## Help Chat Text
   384  
   385  The text for getting chat help. This property maps directly to the `help.chatText` field in the `argocd-cm` ConfigMap.
   386  
   387  ### Help Chat Text Example
   388  
   389  The following example sets the default value in the `argocd-cm` ConfigMap using the `HelpChatText` property on the `ArgoCD` resource.
   390  
   391  ``` yaml
   392  apiVersion: argoproj.io/v1alpha1
   393  kind: ArgoCD
   394  metadata:
   395    name: example-argocd
   396    labels:
   397      example: help-chat-text
   398  spec:
   399    helpChatText: "Chat now!"
   400  ```
   401  
   402  ## Image
   403  
   404  The container image for all Argo CD components.
   405  
   406  ### Image Example
   407  
   408  The following example sets the default value using the `Image` property on the `ArgoCD` resource.
   409  
   410  ``` yaml
   411  apiVersion: argoproj.io/v1alpha1
   412  kind: ArgoCD
   413  metadata:
   414    name: example-argocd
   415    labels:
   416      example: image
   417  spec:
   418    image: argoproj/argocd
   419  ```
   420  
   421  ## Import Options
   422  
   423  The `Import` property allows for the import of an existing `ArgoCDExport` resource. An ArgoCDExport object represents an Argo CD cluster at a point in time that was exported using the `argocd-util` export capability.
   424  
   425  The following properties are available for configuring the import process.
   426  
   427  Name | Default | Description
   428  --- | --- | ---
   429  Name | [Empty] | The name of an ArgoCDExport from which to import data.
   430  Namespace | [ArgoCD Namepspace] |  The Namespace for the ArgoCDExport, defaults to the same namespace as the ArgoCD.
   431  
   432  ### Import Example
   433  
   434  The following example shows the use of the `Import` properties to specify the name of an existing `ArgoCDExport` resource.
   435  
   436  ``` yaml
   437  apiVersion: argoproj.io/v1alpha1
   438  kind: ArgoCD
   439  metadata:
   440    name: example-argocd
   441    labels:
   442      example: import
   443  spec:
   444    import:
   445      name: example-argocdexport
   446      namespace: argocd
   447  ```
   448  
   449  When `Import` properties are specified on the `ArgoCD` resource, the operator will create an init-container on the
   450  Argo CD Application Controller Pod that will use the built-in Argo CD import command to create the resources defined
   451  in an export YAML file that was generated by the referenced `ArgoCDExport` resource.
   452  
   453  To aid in troubleshooting, view the logs from the init-container. Output similar to what is show below indicates a
   454  successful import.
   455  
   456  ``` bash
   457  importing argo-cd
   458  decrypting argo-cd backup
   459  loading argo-cd backup
   460  /ConfigMap argocd-cm updated
   461  /ConfigMap argocd-rbac-cm updated
   462  /ConfigMap argocd-ssh-known-hosts-cm updated
   463  /ConfigMap argocd-tls-certs-cm updated
   464  /Secret argocd-secret updated
   465  argoproj.io/AppProject default unchanged
   466  argo-cd import complete
   467  ```
   468  
   469  ## Initial Repositories
   470  
   471  Initial git repositories to configure Argo CD to use upon creation of the cluster.
   472  
   473  This property maps directly to the `repositories` field in the `argocd-cm` ConfigMap. Updating this property after the cluster has been created has no affect and should be used only as a means to initialize the cluster with the value provided. Modifications to the `repositories` field should then be made through the Argo CD web UI or CLI.
   474  
   475  ### Initial Repositories Example
   476  
   477  The following example sets a value in the `argocd-cm` ConfigMap using the `InitialRepositories` property on the `ArgoCD` resource.
   478  
   479  ``` yaml
   480  apiVersion: argoproj.io/v1alpha1
   481  kind: ArgoCD
   482  metadata:
   483    name: example-argocd
   484    labels:
   485      example: initial-repositories
   486  spec:
   487    initialRepositories: |
   488      - url: https://github.com/argoproj/my-private-repository
   489        passwordSecret:
   490          name: my-secret
   491          key: password
   492        usernameSecret:
   493          name: my-secret
   494          key: username
   495        sshPrivateKeySecret:
   496          name: my-secret
   497          key: sshPrivateKey
   498      - type: helm
   499        url: https://storage.googleapis.com/istio-prerelease/daily-build/master-latest-daily/charts
   500        name: istio.io
   501      - type: helm
   502        url: https://my-private-chart-repo.internal
   503        name: private-repo
   504        usernameSecret:
   505          name: my-secret
   506          key: username
   507        passwordSecret:
   508          name: my-secret
   509          key: password
   510      - type: git
   511        url: https://github.com/argoproj/argocd-example-apps.git
   512  ```
   513  
   514  ## Notifications Controller Options
   515  
   516  The following properties are available for configuring the Notifications controller component.
   517  
   518  Name | Default | Description
   519  --- | --- | ---
   520  Enabled | `false` | The toggle that determines whether notifications-controller should be started or not.
   521  Env | [Empty] | Environment to set for the notifications workloads.
   522  Image | `argoproj/argocd` | The container image for all Argo CD components. This overrides the `ARGOCD_IMAGE` environment variable.
   523  Version | *(recent Argo CD version)* | The tag to use with the Notifications container image.
   524  Resources | [Empty] | The container compute resources.
   525  LogLevel | info | The log level to be used by the ArgoCD Application Controller component. Valid options are debug, info, error, and warn.
   526  
   527  ### Notifications Controller Example
   528  
   529  The following example shows all properties set to the default values.
   530  
   531  ``` yaml
   532  apiVersion: argoproj.io/v1alpha1
   533  kind: ArgoCD
   534  metadata:
   535    name: example-argocd
   536  spec:
   537    notifications:
   538      enabled: true
   539  ```
   540  
   541  ## Repository Credentials
   542  
   543  Git repository credential templates to configure Argo CD to use upon creation of the cluster.
   544  
   545  This property maps directly to the `repository.credentials` field in the `argocd-cm` ConfigMap.
   546  
   547  ### Repository Credentials Example
   548  
   549  The following example sets a value in the `argocd-cm` ConfigMap using the `RepositoryCredentials` property on the `ArgoCD` resource.
   550  
   551  ``` yaml
   552  apiVersion: argoproj.io/v1alpha1
   553  kind: ArgoCD
   554  metadata:
   555    name: example-argocd
   556    labels:
   557      example: repository-credentials
   558  spec:
   559    repositoryCredentials: |
   560      - sshPrivateKeySecret:
   561          key: sshPrivateKey
   562          name: my-ssh-secret
   563        type: git
   564        url: ssh://git@gitlab.com/my-org/
   565  ```
   566  
   567  ## Initial SSH Known Hosts
   568  
   569  Initial SSH Known Hosts for Argo CD to use upon creation of the cluster.
   570  
   571  This property maps directly to the `ssh_known_hosts` field in the `argocd-ssh-known-hosts-cm` ConfigMap. Updating this property after the cluster has been created has no affect and should be used only as a means to initialize the cluster with the value provided. Modifications to the `ssh_known_hosts` field should then be made through the Argo CD web UI or CLI.
   572  
   573  The following properties are available for configuring the import process.
   574  
   575  Name | Default | Description
   576  --- | --- | ---
   577  ExcludeDefaultHosts | false | Whether you would like to exclude the default SSH Hosts entries that ArgoCD provides
   578  Keys | "" | Additional SSH Hosts entries that you would like to include with ArgoCD
   579  
   580  ### Initial SSH Known Hosts Example
   581  
   582  The following example sets a value in the `argocd-ssh-known-hosts-cm` ConfigMap using the `InitialSSHKnownHosts` property on the `ArgoCD` resource. The example values have been truncated for clarity.
   583  
   584  ``` yaml
   585  apiVersion: argoproj.io/v1alpha1
   586  kind: ArgoCD
   587  metadata:
   588    name: example-argocd
   589    labels:
   590      example: initial-ssh-known-hosts
   591  spec:
   592    initialSSHKnownHosts:
   593      excludedefaulthosts: false
   594      keys: |
   595        my-git.org ssh-rsa AAAAB3NzaC...
   596        my-git.com ssh-rsa AAAAB3NzaC...
   597  ```
   598  
   599  ## Kustomize Build Options
   600  
   601  Build options/parameters to use with `kustomize build` (optional). This property maps directly to the `kustomize.buildOptions` field in the `argocd-cm` ConfigMap.
   602  
   603  ### Kustomize Build Options Example
   604  
   605  The following example sets a value in the `argocd-cm` ConfigMap using the `KustomizeBuildOptions` property on the `ArgoCD` resource.
   606  
   607  ``` yaml
   608  apiVersion: argoproj.io/v1alpha1
   609  kind: ArgoCD
   610  metadata:
   611    name: example-argocd
   612    labels:
   613      example: kustomize-build-options
   614  spec:
   615    kustomizeBuildOptions: --load_restrictor none
   616  ```
   617  
   618  ## KustomizeVersions Options
   619  
   620  A list of configured Kustomize versions within your ArgoCD Repo Server Container Image. For each version, this generates the `kustomize.version.vX.Y.Z` field in the `argocd-cm` ConfigMap.
   621  
   622  The following properties are available for each item in the KustomizeVersions list.
   623  
   624  Name | Default | Description
   625  --- | --- | ---
   626  Version | "" | The Kustomize version in the format vX.Y.Z that is configured in your ArgoCD Repo Server container image.
   627  Path | "" | The path to the specified kustomize version on the file system within your ArgoCD Repo Server container image.
   628  
   629  ## KustomizeVersions Example
   630  
   631  The following example configures additional Kustomize versions that are available within the ArgoCD Repo Server container image. These versions already need to be made available via a custom image. Only setting these properties in your ConfigMap does not automatically make them available if they are already not there.
   632  
   633  ```yaml
   634  apiVersion: argoproj.io/v1alpha1
   635  kind: ArgoCD
   636  metadata:
   637    name: example-argocd
   638    labels:
   639      example: kustomize-versions
   640  spec:
   641    kustomizeVersions:
   642      - version: v4.1.0
   643        path: /path/to/kustomize-4.1
   644      - version: v3.5.4
   645        path: /path/to/kustomize-3.5.4
   646  ```
   647  
   648  ## OIDC Config
   649  
   650  OIDC configuration as an alternative to dex (optional). This property maps directly to the `oidc.config` field in the `argocd-cm` ConfigMap.
   651  
   652  ### OIDC Config Example
   653  
   654  The following example sets a value in the `argocd-cm` ConfigMap using the `oidcConfig` property on the `ArgoCD` resource.
   655  
   656  ``` yaml
   657  apiVersion: argoproj.io/v1alpha1
   658  kind: ArgoCD
   659  metadata:
   660    name: example-argocd
   661    labels:
   662      example: oidc-config
   663  spec:
   664    oidcConfig: |
   665      name: Okta
   666      issuer: https://dev-123456.oktapreview.com
   667      clientID: aaaabbbbccccddddeee
   668      clientSecret: $oidc.okta.clientSecret
   669      # Optional set of OIDC scopes to request. If omitted, defaults to: ["openid", "profile", "email", "groups"]
   670      requestedScopes: ["openid", "profile", "email"]
   671      # Optional set of OIDC claims to request on the ID token.
   672      requestedIDTokenClaims: {"groups": {"essential": true}}
   673  ```
   674  
   675  ## NodePlacement Option
   676  
   677  The following properties are available for configuring the NodePlacement component.
   678  
   679  Name | Default | Description
   680  --- | --- | ---
   681  NodeSelector | [Empty] | A map of key value pairs for node selection.
   682  Tolerations | [Empty] | Tolerations allow pods to schedule on nodes with matching taints.
   683  
   684  ### NodePlacement Example
   685  
   686  The following example sets a NodeSelector and tolerations using NodePlacement property in the ArgoCD CR
   687  
   688  ``` yaml
   689  apiVersion: argoproj.io/v1alpha1
   690  kind: ArgoCD
   691  metadata:
   692    name: example-argocd
   693    labels:
   694      example: nodeplacement-example
   695  spec:
   696    nodePlacement:
   697      nodeSelector:
   698        key1: value1
   699      tolerations:
   700      - key: key1
   701        operator: Equal
   702        value: value1
   703        effect: NoSchedule
   704      - key: key1
   705        operator: Equal
   706        value: value1
   707        effect: NoExecute
   708  ```
   709  
   710  ## Prometheus Options
   711  
   712  The following properties are available for configuring the Prometheus component.
   713  
   714  Name | Default | Description
   715  --- | --- | ---
   716  Enabled | false | Toggle Prometheus support globally for ArgoCD.
   717  Host | `example-argocd-prometheus` | The hostname to use for Ingress/Route resources.
   718  Ingress | `false` | Toggles Ingress for Prometheus.
   719  [Route](#prometheus-route-options) | [Object] | Route configuration options.
   720  Size | 1 | The replica count for the Prometheus StatefulSet.
   721  
   722  ### Prometheus Ingress Options
   723  
   724  The following properties are available for configuring the Prometheus Ingress.
   725  
   726  Name | Default | Description
   727  --- | --- | ---
   728  Annotations | [Empty] | The map of annotations to use for the Ingress resource.
   729  Enabled | `false` | Toggle creation of an Ingress resource.
   730  IngressClassName | [Empty] | IngressClass to use for the Ingress resource.
   731  Path | `/` | Path to use for Ingress resources.
   732  TLS | [Empty] | TLS configuration for the Ingress.
   733  
   734  ### Prometheus Route Options
   735  
   736  The following properties are available to configure the Route for the Prometheus component.
   737  
   738  Name | Default | Description
   739  --- | --- | ---
   740  Annotations | [Empty] | The map of annotations to add to the Route.
   741  Enabled | `false` | Toggles the creation of a Route for the Prometheus component.
   742  Labels | [Empty] | The map of labels to add to the Route.
   743  Path | `/` | The path for the Route.
   744  TLS | [Object] | The TLSConfig for the Route.
   745  WildcardPolicy| `None` | The wildcard policy for the Route. Can be one of `Subdomain` or `None`.
   746  
   747  ### Prometheus Example
   748  
   749  The following example shows all properties set to the default values.
   750  
   751  ``` yaml
   752  apiVersion: argoproj.io/v1alpha1
   753  kind: ArgoCD
   754  metadata:
   755    name: example-argocd
   756    labels:
   757      example: insights
   758  spec:
   759    prometheus:
   760      enabled: false
   761      host: example-argocd-prometheus
   762      ingress:
   763        enabled: false
   764      route: false
   765      size: 1
   766  ```
   767  
   768  ## RBAC Options
   769  
   770  The following properties are available for configuring RBAC for the Argo CD cluster.
   771  
   772  Name | Default | Description
   773  --- | --- | ---
   774  DefaultPolicy | `role:readonly` | The `policy.default` property in the `argocd-rbac-cm` ConfigMap. The name of the default role which Argo CD will falls back to, when authorizing API requests.
   775  Policy | [Empty] | The `policy.csv` property in the `argocd-rbac-cm` ConfigMap. CSV data containing user-defined RBAC policies and role definitions.
   776  PolicyMatcherMode | `glob` | The `policy.matchMode` property in the `argocd-rbac-cm` ConfigMap. There are two options for this, 'glob' for glob matcher and 'regex' for regex matcher.
   777  Scopes | `[groups]` | The `scopes` property in the `argocd-rbac-cm` ConfigMap.  Controls which OIDC scopes to examine during rbac enforcement (in addition to `sub` scope).
   778  
   779  ### RBAC Example
   780  
   781  The following example shows all properties set to the default values.
   782  
   783  ``` yaml
   784  apiVersion: argoproj.io/v1alpha1
   785  kind: ArgoCD
   786  metadata:
   787    name: example-argocd
   788    labels:
   789      example: rbac
   790  spec:
   791    rbac:
   792      defaultPolicy: 'role:readonly'
   793      policyMatcherMode: 'glob'
   794      policy: |
   795        g, system:cluster-admins, role:admin
   796      scopes: '[groups]'
   797  ```
   798  
   799  ## Redis Options
   800  
   801  The following properties are available for configuring the Redis component.
   802  
   803  Name | Default | Description
   804  --- | --- | ---
   805  AutoTLS | "" | Provider to use for creating the redis server's TLS certificate (one of: `openshift`). Currently only available for OpenShift.
   806  DisableTLSVerification | false | defines whether the redis server should be accessed using strict TLS validation
   807  Image | `redis` | The container image for Redis. This overrides the `ARGOCD_REDIS_IMAGE` environment variable.
   808  Resources | [Empty] | The container compute resources.
   809  Version | 5.0.3 (SHA) | The tag to use with the Redis container image.
   810  
   811  ### Redis Example
   812  
   813  The following example shows all properties set to the default values.
   814  
   815  ``` yaml
   816  apiVersion: argoproj.io/v1alpha1
   817  kind: ArgoCD
   818  metadata:
   819    name: example-argocd
   820    labels:
   821      example: redis
   822  spec:
   823    redis:
   824      image: redis
   825      resources: {}
   826      version: "5.0.3"
   827      disableTLSVerification: false
   828      autotls: ""
   829  ```
   830  
   831  ## Repo Options
   832  
   833  The following properties are available for configuring the Repo server component.
   834  
   835  Name | Default | Description
   836  --- | --- | ---
   837  [ExtraRepoCommandArgs](#pass-command-arguments-to-repo-server) | [Empty] | Extra Command arguments allows users to pass command line arguments to repo server workload. They get added to default command line arguments provided by the operator.
   838  Resources | [Empty] | The container compute resources.
   839  MountSAToken | false | Whether the ServiceAccount token should be mounted to the repo-server pod.
   840  ServiceAccount | "" | The name of the ServiceAccount to use with the repo-server pod.
   841  VerifyTLS | false | Whether to enforce strict TLS checking on all components when communicating with repo server
   842  AutoTLS | "" | Provider to use for setting up TLS the repo-server's gRPC TLS certificate (one of: `openshift`). Currently only available for OpenShift.
   843  Image | `argoproj/argocd` | The container image for ArgoCD Repo Server. This overrides the `ARGOCD_REPOSERVER_IMAGE` environment variable.
   844  Version | same as `.spec.Version` | The tag to use with the ArgoCD Repo Server.
   845  LogLevel | info | The log level to be used by the ArgoCD Repo Server. Valid options are debug, info, error, and warn.
   846  LogFormat | text | The log format to be used by the ArgoCD Repo Server. Valid options are text or json.
   847  ExecTimeout | 180 | Execution timeout in seconds for rendering tools (e.g. Helm, Kustomize)
   848  Env | [Empty] | Environment to set for the repository server workloads
   849  Replicas | [Empty] | The number of replicas for the ArgoCD Repo Server. Must be greater than or equal to 0.
   850  
   851  ### Pass Command Arguments To Repo Server
   852  
   853  Allows a user to pass additional arguments to Argo CD Repo Server command.
   854  
   855  Name | Default | Description
   856  --- | --- | ---
   857  ExtraCommandArgs | [Empty] | Extra Command arguments allows users to pass command line arguments to repo server workload. They get added to default command line arguments
   858  provided by the operator.
   859  
   860  !!! note
   861      The command line arguments provided as part of ExtraRepoCommandArgs will not overwrite the default command line arguments created by the operator.
   862  
   863  ### Repo Server Example
   864  
   865  The following example shows all properties set to the default values.
   866  
   867  ``` yaml
   868  apiVersion: argoproj.io/v1alpha1
   869  kind: ArgoCD
   870  metadata:
   871    name: example-argocd
   872    labels:
   873      example: repo
   874  spec:
   875    repo:
   876      resources: {}
   877      mountsatoken: false
   878      serviceaccount: ""
   879      verifytls: false
   880      autotls: ""
   881      replicas: 1
   882  ```
   883  
   884  ### Repo Server Command Arguments Example
   885  
   886  ``` yaml
   887  apiVersion: argoproj.io/v1alpha1
   888  kind: ArgoCD
   889  metadata:
   890    name: example-argocd
   891    labels:
   892      example: server
   893  spec:
   894    repo:
   895      extraRepoCommandArgs:
   896        - --reposerver.max.combined.directory.manifests.size
   897        - 10M
   898  ```
   899  
   900  ## Resource Customizations
   901  
   902  Resource behavior can be customized using subkeys (`resourceHealthChecks`, `resourceIgnoreDifferences`, and `resourceActions`). Each of the subkeys maps directly to their own field in the `argocd-cm`. `resourceHealthChecks` will map to `resource.customizations.health`, `resourceIgnoreDifferences` to `resource.customizations.ignoreDifferences`, and `resourceActions` to `resource.customizations.actions`.
   903  
   904  !!! note
   905      `.spec.resourceCustomizations` field is no longer in support from Argo CD Operator v0.8.0 onward. Consider using `resourceHealthChecks`, `resourceIgnoreDifferences`, and `resourceActions` instead.
   906  
   907  ### Resource Customizations (with subkeys)
   908  
   909  Keys for `resourceHealthChecks`, `resourceIgnoreDifferences`, and `resourceActions` are in the form (respectively): `resource.customizations.health.<group_kind>`, `resource.customizations.ignoreDifferences.<group_kind>`, and `resource.customizations.actions.<group_kind>`.
   910  
   911  #### Application Level Configuration
   912  
   913  Argo CD allows ignoring differences at a specific JSON path, using [RFC6902 JSON patches](https://tools.ietf.org/html/rfc6902) and [JQ path expressions](https://stedolan.github.io/jq/manual/#path(path_expression)). It is also possible to ignore differences from fields owned by specific managers defined in `metadata.managedFields` in live resources.
   914  
   915  The following sample application is configured to ignore differences in `spec.replicas` for all deployments:
   916  
   917  ```yaml
   918  spec:
   919    resourceIgnoreDifferences:
   920      resourceIdentifiers:
   921      - group: apps
   922        kind: Deployment
   923        customization:
   924          jsonPointers:
   925          - /spec/replicas
   926  ```
   927  
   928  Note that the `group` field relates to the [Kubernetes API group](https://kubernetes.io/docs/reference/using-api/#api-groups) without the version.
   929  
   930  To ignore elements of a list, you can use JQ path expressions to identify list items based on item content:
   931  ```yaml
   932  spec:
   933    resourceIgnoreDifferences:
   934      resourceIdentifiers:
   935      - group: apps
   936        kind: Deployment
   937        customization:
   938          jqPathExpressions:
   939          - .spec.template.spec.initContainers[] | select(.name == "injected-init-container")
   940  ```
   941  
   942  The following example defines a custom health check in the `argocd-cm` ConfigMap:
   943  ``` yaml
   944  spec:
   945    resourceHealthChecks:
   946      - group: certmanager.k8s.io
   947        kind: Certificate
   948        check: |
   949          hs = {}
   950          if obj.status ~= nil then
   951            if obj.status.conditions ~= nil then
   952              for i, condition in ipairs(obj.status.conditions) do
   953                if condition.type == "Ready" and condition.status == "False" then
   954                  hs.status = "Degraded"
   955                  hs.message = condition.message
   956                  return hs
   957                end
   958                if condition.type == "Ready" and condition.status == "True" then
   959                  hs.status = "Healthy"
   960                  hs.message = condition.message
   961                  return hs
   962                end
   963              end
   964            end
   965          end
   966          hs.status = "Progressing"
   967          hs.message = "Waiting for certificate"
   968          return hs
   969  ```
   970  
   971  The following example defines a custom action in the `argocd-cm` ConfigMap:
   972  ``` yaml
   973  spec:
   974    resourceActions:
   975      - group: apps
   976        kind: Deployment
   977        action: |
   978          discovery.lua: |
   979          actions = {}
   980          actions["restart"] = {}
   981          return actions
   982          definitions:
   983          - name: restart
   984            # Lua Script to modify the obj
   985            action.lua: |
   986              local os = require("os")
   987              if obj.spec.template.metadata == nil then
   988                  obj.spec.template.metadata = {}
   989              end
   990              if obj.spec.template.metadata.annotations == nil then
   991                  obj.spec.template.metadata.annotations = {}
   992              end
   993              obj.spec.template.metadata.annotations["kubectl.kubernetes.io/restartedAt"] = os.date("!%Y-%m-%dT%XZ")
   994              return obj
   995  ```
   996  
   997  After applying these changes your `argocd-cm` Configmap should contain the following fields:
   998  
   999  ```
  1000  resource.customizations.ignoreDifferences.apps_Deployment: |
  1001    jsonPointers:
  1002    - /spec/replicas
  1003    jqPathExpressions:
  1004    - .spec.template.spec.initContainers[] | select(.name == "injected-init-container")
  1005  
  1006  resource.customizations.health.certmanager.k8s.io_Certificate: |
  1007    hs = {}
  1008    if obj.status ~= nil then
  1009      if obj.status.conditions ~= nil then
  1010        for i, condition in ipairs(obj.status.conditions) do
  1011          if condition.type == "Ready" and condition.status == "False" then
  1012            hs.status = "Degraded"
  1013            hs.message = condition.message
  1014            return hs
  1015          end
  1016          if condition.type == "Ready" and condition.status == "True" then
  1017            hs.status = "Healthy"
  1018            hs.message = condition.message
  1019            return hs
  1020          end
  1021        end
  1022      end
  1023    end
  1024    hs.status = "Progressing"
  1025    hs.message = "Waiting for certificate"
  1026    return hs
  1027  
  1028  resource.customizations.actions.apps_Deployment: |
  1029    discovery.lua: |
  1030    actions = {}
  1031    actions["restart"] = {}
  1032    return actions
  1033    definitions:
  1034    - name: restart
  1035      # Lua Script to modify the obj
  1036      action.lua: |
  1037        local os = require("os")
  1038        if obj.spec.template.metadata == nil then
  1039            obj.spec.template.metadata = {}
  1040        end
  1041        if obj.spec.template.metadata.annotations == nil then
  1042            obj.spec.template.metadata.annotations = {}
  1043        end
  1044        obj.spec.template.metadata.annotations["kubectl.kubernetes.io/restartedAt"] = os.date("!%Y-%m-%dT%XZ")
  1045        return obj
  1046  ```
  1047  
  1048  #### System-Level Configuration
  1049  The comparison of resources with well-known issues can be customized at a system level. Ignored differences can be configured for a specified group and kind in `resource.customizations` key of `argocd-cm` ConfigMap. Following is an example of a customization which ignores the `caBundle` field of a `MutatingWebhookConfiguration` webhooks:
  1050  
  1051  ```yaml
  1052  spec:
  1053    resourceIgnoreDifferences:
  1054      resourceIdentifiers:
  1055      - group: admissionregistration.k8s.io
  1056        kind: MutatingWebhookConfiguration
  1057        customization:
  1058          jqPathExpressions:
  1059          - '.webhooks[]?.clientConfig.caBundle'
  1060  ```
  1061  
  1062  Resource customization can also be configured to ignore all differences made by a `managedField.manager` at the system level. The example bellow shows how to configure ArgoCD to ignore changes made by `kube-controller-manager` in `Deployment` resources.
  1063  
  1064  ```yaml
  1065  spec:
  1066    resourceIgnoreDifferences:
  1067      resourceIdentifiers:
  1068      - group: apps
  1069        kind: Deployment
  1070        customization:
  1071          managedFieldsManagers:
  1072          - kube-controller-manager
  1073  ```
  1074  
  1075  It is possible to configure ignoreDifferences to be applied to all resources in every Application managed by an ArgoCD instance. In order to do so, resource customizations can be configured like in the example below:
  1076  
  1077  ```yaml
  1078  spec:
  1079    resourceIgnoreDifferences:
  1080      all:
  1081        managedFieldsManagers:
  1082          - kube-controller-manager
  1083        jsonPointers:
  1084          - /spec/replicas
  1085  ```
  1086  
  1087  After applying these changes your `argocd-cm` Configmap should contain the following fields:
  1088  
  1089  ```
  1090  resource.customizations.ignoreDifferences.admissionregistration.k8s.io_MutatingWebhookConfiguration: |
  1091    jqPathExpressions:
  1092    - '.webhooks[]?.clientConfig.caBundle'
  1093  
  1094  resource.customizations.ignoreDifferences.apps_Deployment: |
  1095    managedFieldsManagers:
  1096    - kube-controller-manager
  1097  
  1098  resource.customizations.ignoreDifferences.all: |
  1099    managedFieldsManagers:
  1100    - kube-controller-manager
  1101    jsonPointers:
  1102    - /spec/replicas
  1103  ```
  1104  
  1105  ## Resource Exclusions
  1106  
  1107  Configuration to completely ignore entire classes of resource group/kinds (optional).
  1108  Excluding high-volume resources improves performance and memory usage, and reduces load and bandwidth to the Kubernetes API server.
  1109  
  1110  These are globs, so a "*" will match all values. If you omit groups/kinds/clusters then they will match all groups/kind/clusters.
  1111  
  1112  NOTE: events.k8s.io and metrics.k8s.io are excluded by default.
  1113  
  1114  This property maps directly to the `resource.exclusions` field in the `argocd-cm` ConfigMap.
  1115  
  1116  ### Resource Exclusions Example
  1117  
  1118  The following example sets a value in the `argocd-cm` ConfigMap using the `ResourceExclusions` property on the `ArgoCD` resource.
  1119  
  1120  ``` yaml
  1121  apiVersion: argoproj.io/v1alpha1
  1122  kind: ArgoCD
  1123  metadata:
  1124    name: example-argocd
  1125    labels:
  1126      example: resource-exclusions
  1127  spec:
  1128    resourceExclusions: |
  1129      - apiGroups:
  1130        - repositories.stash.appscode.com
  1131        kinds:
  1132        - Snapshot
  1133        clusters:
  1134        - "*.local"
  1135  ```
  1136  
  1137  ## Resource Inclusions
  1138  
  1139  In addition to exclusions, you might configure the list of included resources using the resourceInclusions setting.
  1140  
  1141  By default, all resource group/kinds are included. The resourceInclusions setting allows customizing the list of included group/kinds.
  1142  
  1143  ### Resource Inclusions Example
  1144  
  1145  The following example sets a value in the `argocd-cm` ConfigMap using the `ResourceInclusions` property on the `ArgoCD` resource.
  1146  
  1147  ```yaml
  1148  apiVersion: argoproj.io/v1alpha1
  1149  kind: ArgoCD
  1150  metadata:
  1151    name: example-argocd
  1152    labels:
  1153      example: resource-inclusion
  1154  spec:
  1155    resourceInclusions: |
  1156      - apiGroups:
  1157        - "*"
  1158        kinds:
  1159        - Deployment
  1160        clusters:
  1161        - https://192.168.0.20
  1162  ```
  1163  
  1164  ## Resource Tracking Method
  1165  
  1166  You can configure which
  1167  [resource tracking method](https://argo-cd.readthedocs.io/en/stable/user-guide/resource_tracking/#choosing-a-tracking-method)
  1168  Argo CD should use to keep track of the resources it manages.
  1169  
  1170  Valid values are:
  1171  
  1172  * `label` - Track resources using a label
  1173  * `annotation` - Track resources using an annotation
  1174  * `annotation+label` - Track resources using both, an annotation and a label
  1175  
  1176  The default is to use `label` as tracking method.
  1177  
  1178  When this value is changed, existing managed resources will re-sync to apply the new tracking method.
  1179  
  1180  ### Resource Tracking Method
  1181  
  1182  The following example sets the resource tracking method to `annotation+label`
  1183  
  1184  ```yaml
  1185  apiVersion: argoproj.io/v1alpha1
  1186  kind: ArgoCD
  1187  metadata:
  1188    name: example-argocd
  1189    labels:
  1190      example: resource-tracking-method
  1191  spec:
  1192    resourceTrackingMethod: annotation+label
  1193  ```
  1194  
  1195  ## Server Options
  1196  
  1197  The following properties are available for configuring the Argo CD Server component.
  1198  
  1199  Name | Default | Description
  1200  --- | --- | ---
  1201  [Autoscale](#server-autoscale-options) | [Object] | Server autoscale configuration options.
  1202  [ExtraCommandArgs](#server-command-arguments) | [Empty] | List of arguments that will be added to the existing arguments set by the operator.
  1203  [GRPC](#server-grpc-options) | [Object] | GRPC configuration options.
  1204  Host | example-argocd | The hostname to use for Ingress/Route resources.
  1205  [Ingress](#server-ingress-options) | [Object] | Ingress configuration for the Argo CD Server component.
  1206  Insecure | false | Toggles the insecure flag for Argo CD Server.
  1207  Resources | [Empty] | The container compute resources.
  1208  Replicas | [Empty] | The number of replicas for the ArgoCD Server. Must be greater than equal to 0. If Autoscale is enabled, Replicas is ignored.
  1209  [Route](#server-route-options) | [Object] | Route configuration options.
  1210  Service.Type | ClusterIP | The ServiceType to use for the Service resource.
  1211  LogLevel | info | The log level to be used by the ArgoCD Server component. Valid options are debug, info, error, and warn.
  1212  LogFormat | text | The log format to be used by the ArgoCD Server component. Valid options are text or json.
  1213  Env | [Empty] | Environment to set for the server workloads
  1214  
  1215  ### Server Autoscale Options
  1216  
  1217  The following properties are available to configure austoscaling for the Argo CD Server component.
  1218  
  1219  Name | Default | Description
  1220  --- | --- | ---
  1221  Enabled | false | Toggle Autoscaling support globally for the Argo CD server component.
  1222  HPA | [Object] | HorizontalPodAutoscaler options for the Argo CD Server component.
  1223  
  1224  !!! note
  1225      When `.spec.server.autoscale.enabled` is set to `true`, the number of required replicas (if set) in `.spec.server.replicas` will be ignored. The final replica count on the server deployment will be controlled by the Horizontal Pod Autoscaler instead.
  1226  
  1227  ### Server Command Arguments
  1228  
  1229  Allows a user to pass arguments to Argo CD Server command.
  1230  
  1231  Name | Default | Description
  1232  --- | --- | ---
  1233  ExtraCommandArgs | [Empty] | List of arguments that will be added to the existing arguments set by the operator.
  1234  
  1235  !!! note
  1236      ExtraCommandArgs will not be added, if one of these commands is already part of the server command with same or different value.
  1237  
  1238  ### Server Command Arguments Example
  1239  
  1240  ``` yaml
  1241  apiVersion: argoproj.io/v1alpha1
  1242  kind: ArgoCD
  1243  metadata:
  1244    name: example-argocd
  1245    labels:
  1246      example: server
  1247  spec:
  1248    server:
  1249      extraCommandArgs:
  1250        - --rootpath
  1251        - /argocd
  1252  ```
  1253  
  1254  ### Server GRPC Options
  1255  
  1256  The following properties are available to configure GRPC for the Argo CD Server component.
  1257  
  1258  Name | Default | Description
  1259  --- | --- | ---
  1260  Host | `example-argocd-grpc` | The hostname to use for Ingress GRPC resources.
  1261  [Ingress](#server-grpc-ingress-options) | [Object] | Ingress configuration for the Argo CD GRPC Server component.
  1262  
  1263  ### Server GRPC Ingress Options
  1264  
  1265  The following properties are available for configuring the Argo CD server GRP Ingress.
  1266  
  1267  Name | Default | Description
  1268  --- | --- | ---
  1269  Annotations | [Empty] | The map of annotations to use for the Ingress resource.
  1270  Enabled | `false` | Toggle creation of an Ingress resource.
  1271  IngressClassName | [Empty] | IngressClass to use for the Ingress resource.
  1272  Path | `/` | Path to use for Ingress resources.
  1273  TLS | [Empty] | TLS configuration for the Ingress.
  1274  
  1275  ### Server Ingress Options
  1276  
  1277  The following properties are available for configuring the Argo CD server Ingress.
  1278  
  1279  Name | Default | Description
  1280  --- | --- | ---
  1281  Annotations | [Empty] | The map of annotations to use for the Ingress resource.
  1282  Enabled | `false` | Toggle creation of an Ingress resource.
  1283  IngressClassName | [Empty] | IngressClass to use for the Ingress resource.
  1284  Path | `/` | Path to use for Ingress resources.
  1285  TLS | [Empty] | TLS configuration for the Ingress.
  1286  
  1287  ### Server Route Options
  1288  
  1289  The following properties are available to configure the Route for the Argo CD Server component.
  1290  
  1291  Name | Default | Description
  1292  --- | --- | ---
  1293  Annotations | [Empty] | The map of annotations to add to the Route.
  1294  Enabled | `false` | Toggles the creation of a Route for the Argo CD Server component.
  1295  Labels | [Empty] | The map of labels to add to the Route.
  1296  Path | `/` | The path for the Route.
  1297  TLS | [Object] | The TLSConfig for the Route.
  1298  WildcardPolicy| `None` | The wildcard policy for the Route. Can be one of `Subdomain` or `None`.
  1299  
  1300  ### Server Example
  1301  
  1302  The following example shows all properties set to the default values.
  1303  
  1304  ``` yaml
  1305  apiVersion: argoproj.io/v1alpha1
  1306  kind: ArgoCD
  1307  metadata:
  1308    name: example-argocd
  1309    labels:
  1310      example: server
  1311  spec:
  1312    server:
  1313      autoscale:
  1314        enabled: false
  1315        hpa:
  1316          maxReplicas: 3
  1317          minReplicas: 1
  1318          scaleTargetRef:
  1319            apiVersion: extensions/v1beta1
  1320            kind: Deployment
  1321            name: example-argocd-server
  1322          targetCPUUtilizationPercentage: 50
  1323      extraCommandArgs:
  1324        - --rootpath
  1325        - /argocd
  1326      grpc:
  1327        host: example-argocd-grpc
  1328        ingress: false
  1329      host: example-argocd
  1330      ingress:
  1331        enabled: false
  1332      insecure: false
  1333      replicas: 1
  1334      resources: {}
  1335      route:
  1336        annotations: {}
  1337        enabled: false
  1338        path: /
  1339        tls:
  1340          insecureEdgeTerminationPolicy: Redirect
  1341          termination: passthrough
  1342        wildcardPolicy: None
  1343      service:
  1344        type: ClusterIP
  1345  ```
  1346  
  1347  ## Status Badge Enabled
  1348  
  1349  Enable application status badge feature. This property maps directly to the `statusbadge.enabled` field in the `argocd-cm` ConfigMap.
  1350  
  1351  ### Status Badge Enabled Example
  1352  
  1353  The following example sets the default value in the `argocd-cm` ConfigMap using the `StatusBadgeEnabled` property on the `ArgoCD` resource.
  1354  
  1355  ``` yaml
  1356  apiVersion: argoproj.io/v1alpha1
  1357  kind: ArgoCD
  1358  metadata:
  1359    name: example-argocd
  1360    labels:
  1361      example: status-badge-enabled
  1362  spec:
  1363    statusBadgeEnabled: true
  1364  ```
  1365  
  1366  ## Single sign-on Options
  1367  
  1368  The following properties are available for configuring the Single sign-on component.
  1369  
  1370  Name | Default | Description
  1371  --- | --- | ---
  1372  [Keycloak](#keycloak-options) | [Object] | Configuration options for Keycloak SSO provider
  1373  [Dex](#dex-options) | [Object] | Configuration options for Dex SSO provider
  1374  Provider | [Empty] | The name of the provider used to configure Single sign-on. For now the supported options are "dex" and "keycloak".
  1375  
  1376  ## Dex Options
  1377  
  1378  The following properties are available for configuring the Dex component.
  1379  
  1380  Name | Default | Description
  1381  --- | --- | ---
  1382  Config | [Empty] | The `dex.config` property in the `argocd-cm` ConfigMap.
  1383  Groups | [Empty] | Optional list of required groups a user must be a member of
  1384  Image | `quay.io/dexidp/dex` | The container image for Dex. This overrides the `ARGOCD_DEX_IMAGE` environment variable.
  1385  OpenShiftOAuth | false | Enable automatic configuration of OpenShift OAuth authentication for the Dex server. This is ignored if a value is present for `sso.dex.config`.
  1386  Resources | [Empty] | The container compute resources.
  1387  Version | v2.21.0 (SHA) | The tag to use with the Dex container image.
  1388  Env | [Empty] | Environment to set for Dex.
  1389  
  1390  ### Dex Example
  1391  
  1392  !!! note
  1393      `.spec.dex` is no longer supported in Argo CD operator v0.8.0 onwards, use `.spec.sso.dex` instead.
  1394  
  1395  The following examples show all properties set to the default values.
  1396  
  1397  ``` yaml
  1398  apiVersion: argoproj.io/v1alpha1
  1399  kind: ArgoCD
  1400  metadata:
  1401    name: example-argocd
  1402    labels:
  1403      example: dex
  1404  spec:
  1405    sso:
  1406      provider: dex
  1407      dex:
  1408        config: ""
  1409        groups:
  1410          - default
  1411        image: quay.io/dexidp/dex
  1412        openShiftOAuth: false
  1413        resources: {}
  1414        version: v2.21.0
  1415  ```
  1416  
  1417  Please refer to the [dex user guide](../usage/dex.md) to learn more about configuring dex as a Single sign-on provider.
  1418  
  1419  ### Dex OpenShift OAuth Example
  1420  
  1421  The following example configures Dex to use the OAuth server built into OpenShift.
  1422  
  1423  The `OpenShiftOAuth` property can be used to trigger the operator to auto configure the built-in OpenShift OAuth server. The RBAC `Policy` property is used to give the admin role in the Argo CD cluster to users in the OpenShift `cluster-admins` group.
  1424  
  1425  ``` yaml
  1426  apiVersion: argoproj.io/v1alpha1
  1427  kind: ArgoCD
  1428  metadata:
  1429    name: example-argocd
  1430    labels:
  1431      example: openshift-oauth
  1432  spec:
  1433    sso:
  1434      provider: dex
  1435      dex:
  1436        openShiftOAuth: true
  1437    rbac:
  1438      defaultPolicy: 'role:readonly'
  1439      policy: |
  1440        g, cluster-admins, role:admin
  1441      scopes: '[groups]'
  1442  ```
  1443  
  1444  ### Important Note regarding Role Mappings:
  1445  
  1446  To have a specific user be properly atrributed with the `role:admin` upon SSO through Openshift, the user needs to be in a **group** with the `cluster-admin` role added. If the user only has a direct `ClusterRoleBinding` to the Openshift role for `cluster-admin`, the ArgoCD role will not map.
  1447  
  1448  A quick fix will be to create an `cluster-admins` group, add the user to the group and then apply the `cluster-admin` ClusterRole to the group.
  1449  
  1450  ```
  1451  oc adm groups new cluster-admins
  1452  oc adm groups add-users cluster-admins USER
  1453  oc adm policy add-cluster-role-to-group cluster-admin cluster-admins
  1454  ```
  1455  
  1456  ## Keycloak Options
  1457  
  1458  The following properties are available for configuring Keycloak Single sign-on provider.
  1459  
  1460  Name | Default | Description
  1461  --- | --- | ---
  1462  Image | OpenShift - `registry.redhat.io/rh-sso-7/sso76-openshift-rhel8` <br/> Kuberentes - `quay.io/keycloak/keycloak` | The container image for keycloak. This overrides the `ARGOCD_KEYCLOAK_IMAGE` environment variable.
  1463  Resources | `Requests`: CPU=500m, Mem=512Mi, `Limits`: CPU=1000m, Mem=1024Mi | The container compute resources.
  1464  RootCA | "" | root CA certificate for communicating with the OIDC provider
  1465  VerifyTLS | true | Whether to enforce strict TLS checking when communicating with Keycloak service.
  1466  Version | OpenShift - `sha256:720a7e4c4926c41c1219a90daaea3b971a3d0da5a152a96fed4fb544d80f52e3` (7.5.1) <br/> Kubernetes - `sha256:64fb81886fde61dee55091e6033481fa5ccdac62ae30a4fd29b54eb5e97df6a9` (15.0.2) | The tag to use with the keycloak container image.
  1467  
  1468  ### Keycloak Single sign-on Example
  1469  
  1470  !!! note
  1471      `.spec.sso.Image`, `.spec.sso.Version`, `.spec.sso.Resources` and `.spec.sso.verifyTLS` fields are no longer supported in Argo CD operator v0.8.0 onwards. Please use equivalent fields under `.spec.sso.keycloak` to configure your keycloak instance.
  1472  
  1473  The following example uses keycloak as Single sign-on option for Argo CD.
  1474  
  1475  ``` yaml
  1476  apiVersion: argoproj.io/v1alpha1
  1477  kind: ArgoCD
  1478  metadata:
  1479    name: example-argocd
  1480    labels:
  1481      example: status-badge-enabled
  1482  spec:
  1483    sso:
  1484      provider: keycloak
  1485  ```
  1486  
  1487  Please refer to the [keycloak user guide](../usage/keycloak/kubernetes.md) to learn more about configuring keycloak as a Single sign-on provider.
  1488  
  1489  ## System-Level Configuration
  1490  
  1491  The comparison of resources with well-known issues can be customized at a system level. Ignored differences can be configured for a specified group and kind
  1492  in `resource.customizations` key of `argocd-cm` ConfigMap. Following is an example of a customization which ignores the `caBundle` field
  1493  of a `MutatingWebhookConfiguration` webhooks:
  1494  
  1495  ```yaml
  1496  data:
  1497    resource.customizations.ignoreDifferences.admissionregistration.k8s.io_MutatingWebhookConfiguration: |
  1498      jqPathExpressions:
  1499      - '.webhooks[]?.clientConfig.caBundle'
  1500  ```
  1501  
  1502  Resource customization can also be configured to ignore all differences made by a `managedFieldsManager` at the system level. The example bellow shows how to configure ArgoCD to ignore changes made by `kube-controller-manager` in `Deployment` resources.
  1503  
  1504  ```yaml
  1505  data:
  1506    resource.customizations.ignoreDifferences.apps_Deployment: |
  1507      managedFieldsManagers:
  1508      - kube-controller-manager
  1509  ```
  1510  
  1511  It is possible to configure ignoreDifferences to be applied to all resources in every Application managed by an ArgoCD instance. In order to do so, resource customizations can be configured like in the example bellow:
  1512  
  1513  ```yaml
  1514  data:
  1515    resource.customizations.ignoreDifferences.all: |
  1516      managedFieldsManagers:
  1517      - kube-controller-manager
  1518      jsonPointers:
  1519      - /spec/replicas
  1520  ```
  1521  
  1522  ## TLS Options
  1523  
  1524  The following properties are available for configuring the TLS settings.
  1525  
  1526  Name | Default | Description
  1527  --- | --- | ---
  1528  CA.ConfigMapName | `example-argocd-ca` | The name of the ConfigMap containing the CA Certificate.
  1529  CA.SecretName | `example-argocd-ca` | The name of the Secret containing the CA Certificate and Key.
  1530  InitialCerts | [Empty] | Initial set of certificates in the `argocd-tls-certs-cm` ConfigMap for connecting Git repositories via HTTPS.
  1531  
  1532  ### TLS Example
  1533  
  1534  The following example shows all properties set to the default values.
  1535  
  1536  ``` yaml
  1537  apiVersion: argoproj.io/v1alpha1
  1538  kind: ArgoCD
  1539  metadata:
  1540    name: example-argocd
  1541    labels:
  1542      example: tls
  1543  spec:
  1544    tls:
  1545      ca:
  1546        configMapName: example-argocd-ca
  1547        secretName: example-argocd-ca
  1548      initialCerts: []
  1549  ```
  1550  
  1551  ### IntialCerts Example
  1552  
  1553  Initial set of repository certificates to be configured in Argo CD upon creation of the cluster.
  1554  
  1555  This property maps directly to the data field in the argocd-tls-certs-cm ConfigMap. Updating this property after the cluster has been created has no affect and should be used only as a means to initialize the cluster with the value provided. Updating new certificates should then be made through the Argo CD web UI or CLI.
  1556  
  1557  ```yaml
  1558  apiVersion: argoproj.io/v1alpha1
  1559  kind: ArgoCD
  1560  metadata:
  1561    name: example-argocd
  1562    labels:
  1563      example: intialCerts
  1564  spec:
  1565    tls:
  1566      ca: {}
  1567      initialCerts:
  1568        test.example.com: |
  1569          -----BEGIN CERTIFICATE-----
  1570          -----END CERTIFICATE-----
  1571  ```
  1572  
  1573  ## Users Anonymous Enabled
  1574  
  1575  Enables anonymous user access. The anonymous users get default role permissions specified `argocd-rbac-cm`.
  1576  
  1577  This property maps directly to the `users.anonymous.enabled` field in the `argocd-cm` ConfigMap.
  1578  
  1579  ### Users Anonymous Enabled Example
  1580  
  1581  The following example sets the default value in the `argocd-cm` ConfigMap using the `UsersAnonymousEnabled` property on the `ArgoCD` resource.
  1582  
  1583  ``` yaml
  1584  apiVersion: argoproj.io/v1alpha1
  1585  kind: ArgoCD
  1586  metadata:
  1587    name: example-argocd
  1588    labels:
  1589      example: users-anonymous-enabled
  1590  spec:
  1591    usersAnonymousEnabled: false
  1592  ```
  1593  
  1594  ## Version
  1595  
  1596  The tag to use with the container image for all Argo CD components.
  1597  
  1598  ### Version Example
  1599  
  1600  The following example sets the default value using the `Version` property on the `ArgoCD` resource.
  1601  
  1602  ``` yaml
  1603  apiVersion: argoproj.io/v1alpha1
  1604  kind: ArgoCD
  1605  metadata:
  1606    name: example-argocd
  1607    labels:
  1608      example: version
  1609  spec:
  1610    version: v1.7.7
  1611  ```
  1612  
  1613  ## Banner
  1614  
  1615  The following properties are available for configuring a [UI banner message](https://argo-cd.readthedocs.io/en/stable/operator-manual/custom-styles/#banners).
  1616  
  1617  Name | Default | Description
  1618  --- | --- | ---
  1619  Banner.Content | [Empty] | The banner message content (required if a banner should be displayed).
  1620  Banner.URL | [Empty] | The banner message link URL (optional).
  1621  
  1622  ### Banner Example
  1623  The following example enables a UI banner with message content and URL.
  1624  
  1625  ``` yaml
  1626  apiVersion: argoproj.io/v1alpha1
  1627  kind: ArgoCD
  1628  metadata:
  1629    name: example-argocd
  1630    labels:
  1631      example: version
  1632  spec:
  1633    banner:
  1634      content: "Custom Styles - Banners"
  1635      url: "https://argo-cd.readthedocs.io/en/stable/operator-manual/custom-styles/#banners"
  1636  ```