github.com/verrazzano/verrazzano@v1.7.0/platform-operator/constants/constants.go (about) 1 // Copyright (c) 2021, 2023, Oracle and/or its affiliates. 2 // Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl. 3 4 package constants 5 6 import "time" 7 8 // VerrazzanoSystemNamespace is the system namespace for verrazzano 9 const VerrazzanoSystemNamespace = "verrazzano-system" 10 11 // VerrazzanoInstallNamespace is the namespace that the platform operator lives in 12 const VerrazzanoInstallNamespace = "verrazzano-install" 13 14 // VerrazzanoMonitoringNamespace is the namespace for monitoring components 15 const VerrazzanoMonitoringNamespace = "verrazzano-monitoring" 16 17 // VerrazzanoLoggingNamespace is the namespace for logging components 18 const VerrazzanoLoggingNamespace = "verrazzano-logging" 19 20 // Verrazzano is the name of the Verrazzano secret in the Verrazzano system namespace 21 const Verrazzano = "verrazzano" 22 23 // VerrazzanoMultiClusterNamespace is the multi-cluster namespace for verrazzano 24 const VerrazzanoMultiClusterNamespace = "verrazzano-mc" 25 26 // MCAgentSecret contains information needed by the agent to access the admin cluster, such as the admin kubeconfig. 27 // This secret is used by the MC agent running on the managed cluster. 28 const MCAgentSecret = "verrazzano-cluster-agent" //nolint:gosec //#gosec G101 29 30 // MCRegistrationSecret contains information which related to the managed cluster itself, such as the 31 // managed cluster name. 32 const MCRegistrationSecret = "verrazzano-cluster-registration" //nolint:gosec //#gosec G101 33 34 // MCLocalRegistrationSecret - the name of the local secret that contains the cluster registration information. 35 // This is created at Verrazzano install. 36 const MCLocalRegistrationSecret = "verrazzano-local-registration" //nolint:gosec //#gosec G101 37 38 // MCClusterRole is the role name for the role used during VMC reconcile 39 const MCClusterRole = "verrazzano-managed-cluster" 40 41 // MCLocalCluster is the name of the local cluster 42 const MCLocalCluster = "local" 43 44 // AdminClusterConfigMapName is the name of the configmap that contains admin cluster server address 45 const AdminClusterConfigMapName = "verrazzano-admin-cluster" 46 47 // ServerDataKey is the key into ConfigMap data for cluster server address 48 const ServerDataKey = "server" 49 50 // VzIngress - the name of the ingress for Verrazzano console and api 51 const VzIngress = "verrazzano-ingress" 52 53 // RegistryOverrideEnvVar is the environment variable name used to override the registry housing images we install 54 const RegistryOverrideEnvVar = "REGISTRY" 55 56 // ImageRepoOverrideEnvVar is the environment variable name used to set the image repository 57 const ImageRepoOverrideEnvVar = "IMAGE_REPO" 58 59 // VerrazzanoAppOperatorImageEnvVar is the environment variable used to override the Verrazzano Application Operator image 60 const VerrazzanoAppOperatorImageEnvVar = "APP_OPERATOR_IMAGE" 61 62 // VerrazzanoClusterOperatorImageEnvVar is the environment variable used to override the Verrazzano Cluster Operator image 63 const VerrazzanoClusterOperatorImageEnvVar = "CLUSTER_OPERATOR_IMAGE" 64 65 // VerrazzanoAuthProxyImageEnvVar is the environment variable used to override the Verrazzano Authproxy image 66 const VerrazzanoAuthProxyImageEnvVar = "AUTH_PROXY_IMAGE" 67 68 // The Kubernetes default namespace 69 const DefaultNamespace = "default" 70 71 const BomVerrazzanoVersion = "VERRAZZANO_VERSION" 72 73 // ClusterNameData - the field name in MCRegistrationSecret that contains this managed cluster's name 74 const ClusterNameData = "managed-cluster-name" 75 76 // OpensearchURLData - the field name in MCRegistrationSecret that contains the admin cluster's 77 // Opensearch endpoint's URL 78 const OpensearchURLData = "es-url" 79 80 // ClusterNameEnvVar is the environment variable used to identify the managed cluster for fluentd 81 const ClusterNameEnvVar = "CLUSTER_NAME" 82 83 // OpensearchURLEnvVar is the environment variable used to identify the admin clusters Opensearch URL 84 const OpensearchURLEnvVar = "OPENSEARCH_URL" 85 86 // OpensearchIngress is the name of the ingress for Opensearch 87 const OpensearchIngress = "opensearch" 88 89 const LegacyOpensearchIngress = "vmi-system-os-ingest" 90 91 // OpensearchdashboardsIngress is the name of the ingress for Opensearchdashboards 92 const OpensearchDashboardsIngress = "opensearch-dashboards" 93 94 const LegacyOpensearchDashboardsIngress = "vmi-system-osd" 95 96 // GrafanaIngress is the name of the ingress for Grafana 97 const GrafanaIngress = "vmi-system-grafana" 98 99 // KibanaIngress is the name of the ingress for Kibana 100 const KibanaIngress = "vmi-system-kibana" 101 102 // PrometheusIngress is the name of the ingress for Prometheus 103 const PrometheusIngress = "vmi-system-prometheus" 104 105 // GlobalImagePullSecName is the name of the global image pull secret 106 const GlobalImagePullSecName = "verrazzano-container-registry" 107 108 // IngressNginxNamespace is the nginx ingress namespace name 109 const IngressNginxNamespace = "verrazzano-ingress-nginx" 110 111 // LegacyIngressNginxNamespace is the old nginx ingress namespace name 112 const LegacyIngressNginxNamespace = "ingress-nginx" 113 114 // IstioSystemNamespace - the Istio system namespace 115 const IstioSystemNamespace = "istio-system" 116 117 // RancherIngress is the name of the ingress for Rancher 118 const RancherIngress = "rancher" 119 120 // KialiIngress is the name of the ingress for Kiali 121 const KialiIngress = "vmi-system-kiali" 122 123 // JaegerIngress is the name of the ingress for Jaeger 124 const JaegerIngress = "verrazzano-jaeger" 125 126 // KeycloakNamespace is the keycloak namespace name 127 const KeycloakNamespace = "keycloak" 128 129 // KeycloakIngress - the name of the ingress for Keycloak console and api 130 const KeycloakIngress = "keycloak" 131 132 // ArgoCDNamespace - the name of the Argo CD namespace 133 const ArgoCDNamespace = "argocd" 134 135 // ArgoCDIngress - the name of the ingress for Argo CD 136 const ArgoCDIngress = "argocd-server" 137 138 // VerrazzanoAuthProxyServiceName is the name of the Verrazzano auth proxy service 139 const VerrazzanoAuthProxyServiceName = "verrazzano-authproxy" 140 141 // VerrazzanoAuthProxyServicePort is the port exposed by the Verrazzano auth proxy service 142 const VerrazzanoAuthProxyServicePort = 8775 143 144 // VerrazzanoAuthProxyGRPCServicePort is the port exposed by the Verrazzano auth proxy service for gRPC traffic 145 const VerrazzanoAuthProxyGRPCServicePort = 8776 146 147 // DefaultEnvironmentName is the default name for install environment 148 const DefaultEnvironmentName = "default" 149 150 // VerrazzanoVersion1_0_0 is the Verrazzano version string for 1.0.0 151 const VerrazzanoVersion1_0_0 = "1.0.0" 152 153 // VerrazzanoVersion1_1_0 is the Verrazzano version string for 1.1.0 154 const VerrazzanoVersion1_1_0 = "1.1.0" 155 156 // VerrazzanoVersion1_3_0 is the Verrazzano version string for 1.3.0 157 const VerrazzanoVersion1_3_0 = "1.3.0" 158 159 // VerrazzanoVersion1_4_0 is the Verrazzano version string for 1.4.0 160 const VerrazzanoVersion1_4_0 = "1.4.0" 161 162 // VerrazzanoVersion1_5_0 is the Verrazzano version string for 1.5.0 163 const VerrazzanoVersion1_5_0 = "1.5.0" 164 165 // VerrazzanoVersion1_6_0 is the Verrazzano version string for 1.6.0 166 const VerrazzanoVersion1_6_0 = "1.6.0" 167 168 // VerrazzanoVersion1_7_0 is the Verrazzano version string for 1.7.0 169 const VerrazzanoVersion1_7_0 = "1.7.0" 170 171 // UpgradeRetryVersion is the restart version annotation field 172 const UpgradeRetryVersion = "verrazzano.io/upgrade-retry-version" 173 174 // ObservedUpgradeRetryVersion is the previous restart version annotation field 175 const ObservedUpgradeRetryVersion = "verrazzano.io/observed-upgrade-retry-version" 176 177 // NGINXControllerServiceName is the nginx ingress controller name 178 const NGINXControllerServiceName = "ingress-controller-ingress-nginx-controller" 179 180 // InstallOperation indicates that an install operation being executed by a component 181 const InstallOperation = "install" 182 183 // UpdateOperation indicates that an update operation being executed by a component 184 const UpdateOperation = "update" 185 186 // UpgradeOperation indicates that an upgrade operation being executed by a component 187 const UpgradeOperation = "upgrade" 188 189 // UninstallOperation indicates that an uninstall operation being executed by a component 190 const UninstallOperation = "uninstall" 191 192 // InitializeOperation indicates that an initialize operation being executed by a component 193 const InitializeOperation = "initialize" 194 195 // ReconcileLoopRequeueInterval is the interval before reconcile gets called again. 196 const ReconcileLoopRequeueInterval = 3 * time.Minute 197 198 // VMISecret is the secret used for VMI 199 const VMISecret = "verrazzano" 200 201 // GrafanaSecret is the secret used for VMI 202 const GrafanaSecret = "grafana-admin" 203 204 // GrafanaDBSecret is the secret used for VMI 205 const GrafanaDBSecret = "grafana-db" 206 207 // VMIBackupSecretName is the backup VMI secret 208 const VMIBackupSecretName = "verrazzano-backup" //nolint:gosec //#gosec G101 209 210 // ObjectStoreAccessKey is used for the VMI backup secret 211 const ObjectStoreAccessKey = "object_store_access_key" 212 213 // ObjectStoreAccessSecretKey is used for the VMI backup secret 214 const ObjectStoreAccessSecretKey = "object_store_secret_key" 215 216 // VerrazzanoIngressSecret is the secret where the verrazzano/console TLS cert, key, and CA(s) are stored 217 const VerrazzanoIngressSecret = "verrazzano-tls" //nolint:gosec //#gosec G101 218 219 // VerrazzanoLocalCABundleSecret is a secret containing the admin ca bundle 220 const VerrazzanoLocalCABundleSecret = "verrazzano-local-ca-bundle" //nolint:gosec //#gosec G101 221 222 // KubernetesAppLabel is a label key for kubernetes apps 223 const KubernetesAppLabel = "app.kubernetes.io/component" 224 225 // JaegerCollectorService is a label value for Jaeger collector 226 const JaegerCollectorService = "service-collector" 227 228 // OverridesFinalizer is a label value for value override object finalizer 229 const OverridesFinalizer = "overrides.finalizers.verrazzano.io/finalizer" 230 231 // DevComponentFinalizer is a label value for dev components configmap finalizer 232 const DevComponentFinalizer = "components.finalizers.verrazzano.io/finalizer" 233 234 // ConfigMapKind is a label value for ConfigMap kind 235 const ConfigMapKind = "ConfigMap" 236 237 // SecretKind is a label value for Secret Kind 238 const SecretKind = "Secret" 239 240 // PromManagedClusterCACertsSecretName is the name of the secret that contains managed cluster CA certificates. The secret is mounted 241 // as a volume in the Prometheus pod. 242 const PromManagedClusterCACertsSecretName = "managed-cluster-ca-certs" 243 244 // VerrazzanoComponentLabelKey is the key for the verrazzano component label to distinguish verrazzano component resources 245 const VerrazzanoComponentLabelKey = "verrazzano-component" 246 247 // IstioAppLabel is the label used for Verrazzano Istio components 248 const IstioAppLabel = "verrazzano.io/istio" 249 250 // OldReclaimPolicyLabel is the name of the label used to store the old reclaim policy of a persistent volume before it is migrated 251 const OldReclaimPolicyLabel = "verrazzano.io/old-reclaim-policy" 252 253 // StorageForLabel is the name of the label applied to a persistent volume so storage can be selected by a pod 254 const StorageForLabel = "verrazzano.io/storage-for" 255 256 // PrometheusStorageLabelValue is the label value for Prometheus storage 257 const PrometheusStorageLabelValue = "prometheus" 258 259 // VMISystemPrometheusVolumeClaim is the name of the VMO-managed Prometheus persistent volume claim 260 const VMISystemPrometheusVolumeClaim = "vmi-system-prometheus" 261 262 // VeleroNameSpace indicates the namespace to be used for velero installation 263 const VeleroNameSpace = "verrazzano-backup" 264 265 // ResticDaemonSetName indicates name of the daemonset that is installed as part of component velero 266 const ResticDaemonSetName = "restic" 267 268 // RancherBackupNamesSpace indicates the namespace to be used for Rancher Backup installation 269 const RancherBackupNamesSpace = "cattle-resources-system" 270 271 // VerrazzanoManagedKey indicates the label key to the Verrazzano managed namespaces 272 const VerrazzanoManagedKey = "verrazzano.io/namespace" 273 274 // ServiceMonitorNameKubelet indicates the name of serviceMonitor resource for kubelet monitoring 275 const ServiceMonitorNameKubelet = "prometheus-operator-kube-p-kubelet" 276 277 // ServiceMonitorNameKubeStateMetrics indicates the name of serviceMonitor resource for kube-state-metrics monitoring 278 const ServiceMonitorNameKubeStateMetrics = "kube-state-metrics" 279 280 // ThanosInternalUserSecretName is the name of the secret used to store the VZ internal Thanos user credentials 281 const ThanosInternalUserSecretName = "verrazzano-thanos-internal" //nolint:gosec //#gosec G101 282 283 // ThanosInternalUserName is the name of the VZ internal Thanos user 284 const ThanosInternalUserName = "verrazzano-thanos-internal" 285 286 // VerrazzanoPlatformOperatorHelmName is the Helm release name of the Verrazzano Platform Operator 287 const VerrazzanoPlatformOperatorHelmName = "verrazzano-platform-operator" 288 289 // VerrazzanoModuleOwnerLabel is the label for the module CR that owns the secret or configmap resource 290 const VerrazzanoModuleOwnerLabel = "module.verrazzano.io/module-owner" 291 292 // VerrazzanoModuleEventLabel is the label for the module events 293 const VerrazzanoModuleEventLabel = "module.verrazzano.io/event" 294 295 // AlertmanagerIngress is the name of the ingress for Alertmanager 296 const AlertmanagerIngress = "alertmanager" 297 298 // DexNamespace is the Dex namespace name 299 const DexNamespace = "verrazzano-auth" 300 301 // DexIngress - the name of the ingress for Dex 302 const DexIngress = "dex" 303 304 // DexHostPrefix - the prefix of the Dex host 305 const DexHostPrefix = "auth" 306 307 // OpenSearchIntegrationConfigMap - the name of the OpenSearch integration configmap 308 const OpenSearchIntegrationConfigMapName = "opensearch-integration"