github.com/olli-ai/jx/v2@v2.0.400-0.20210921045218-14731b4dd448/pkg/kube/constants.go (about) 1 package kube 2 3 const ( 4 // DefaultChartMuseumURL default URL for Jenkins X Charts 5 DefaultChartMuseumURL = "https://jenkins-x-charts.github.io/v2" 6 // DefaultChartMuseumJxRepoName default repo name for Jenkins X Charts 7 DefaultChartMuseumJxRepoName = "jenkins-x" 8 9 // ChartAmbassador the default chart for ambassador 10 ChartAmbassador = "datawire/ambassador" 11 12 // ChartAnchore the default chart for the Anchore plugin 13 ChartAnchore = "stable/anchore-engine" 14 15 // ChartExposecontrollerService the default name of the Exposecontroller Service chart for Edit environments 16 ChartExposecontrollerService = "jenkins-x/exposecontroller-service" 17 18 // ChartAnchore the default chart for the Anchore plugin 19 ChartPipelineEvent = "jenkins-x/pipeline-events-addon" 20 21 // ChartGitea the default name of the gitea chart 22 ChartGitea = "jenkins-x/gitea" 23 24 // ChartFlagger the default chart for the Flagger chart 25 ChartFlagger = "flagger/flagger" 26 ChartFlaggerGrafana = "flagger/grafana" 27 DefaultFlaggerReleaseName = "flagger" 28 29 // ChartIstio the default chart for the Istio chart 30 ChartIstio = "install/kubernetes/helm/istio" 31 32 // ChartKubeless the default chart for kubeless 33 ChartKubeless = "incubator/kubeless" 34 35 // ChartProw the default chart for Prow 36 ChartProw = "jenkins-x/prow" 37 38 // ChartKnative the default chart for knative 39 ChartKnativeBuild = "jenkins-x/knative-build" 40 41 // ChartBuildTemplates the build templates for Knative Build 42 ChartBuildTemplates = "jenkins-x/jx-build-templates" 43 44 // ChartTekton the default chart for tekton 45 ChartTekton = "jenkins-x/tekton" 46 47 // DefaultProwReleaseName the default helm release name for Prow 48 DefaultProwReleaseName = "jx-prow" 49 50 // DefaultKnativeBuildReleaseName the default helm release name for knative build 51 DefaultKnativeBuildReleaseName = "knative-build" 52 53 // DefaultTektonReleaseName the default helm release name for tekton 54 DefaultTektonReleaseName = "tekton" 55 56 // DefaultBuildTemplatesReleaseName the default helm release name for the knative build templates 57 DefaultBuildTemplatesReleaseName = "jx-build-templates" 58 59 // Charts Single Sign-On addon 60 ChartSsoOperator = "jenkins-x/sso-operator" 61 DefaultSsoOperatorReleaseName = "jx-sso-operator" 62 ChartSsoDex = "jenkins-x/dex" 63 DefaultSsoDexReleaseName = "jx-sso-dex" 64 65 // ChartVaultOperator the default chart for vault opeator 66 ChartVaultOperator = "jenkins-x/vault-operator" 67 DefaultVaultOperatorReleaseName = "vault-operator" 68 69 //ChartExternalDNS the default chart for external-dns 70 ChartOwnerExternalDNS = "bitnami" 71 ChartURLExternalDNS = "https://charts.bitnami.com/bitnami" 72 ChartExternalDNS = "bitnami/external-dns" 73 DefaultExternalDNSReleaseName = "external-dns" 74 DefaultExternalDNSTag = "1.5.2" 75 76 // SecretKaniko the name of the secret containing the kaniko service account 77 SecretKaniko = "kaniko-secret" 78 79 // SecretVelero the name of the secret containing the velero service account 80 SecretVelero = "velero-secret" // #nosec 81 82 // ServiceJenkins is the name of the Jenkins Service 83 ServiceJenkins = "jenkins" 84 85 // SecretJenkins is the name of the Jenkins secret 86 SecretJenkins = "jenkins" 87 88 // ServiceChartMuseum the service name of the Helm ChartMuseum service 89 ServiceChartMuseum = "jenkins-x-chartmuseum" 90 91 // ServiceKubernetesDashboard the Kubernetes dashboard 92 ServiceKubernetesDashboard = "jenkins-x-kubernetes-dashboard" 93 94 // SecretJenkinsChartMuseum the chart museum secret 95 SecretJenkinsChartMuseum = "jenkins-x-chartmuseum" 96 97 // SecretBucketRepo the bucket repo secret if using it as a chart repositoru 98 SecretBucketRepo = "jenkins-x-bucketrepo" 99 100 // SecretJenkinsReleaseGPG the GPG secrets for doing releases 101 SecretJenkinsReleaseGPG = "jenkins-release-gpg" 102 103 // SecretJenkinsPipelinePrefix prefix for a jenkins pipeline secret name 104 SecretJenkinsPipelinePrefix = "jx-pipeline-" 105 106 // SecretJenkinsPipelineAddonCredentials the chat credentials secret 107 SecretJenkinsPipelineAddonCredentials = "jx-pipeline-addon-" // #nosec 108 109 // SecretJenkinsPipelineChatCredentials the chat credentials secret 110 SecretJenkinsPipelineChatCredentials = "jx-pipeline-chat-" 111 112 // SecretJenkinsPipelineGitCredentials the git credentials secret 113 SecretJenkinsPipelineGitCredentials = "jx-pipeline-git-" // #nosec 114 115 // SecretJenkinsPipelineIssueCredentials the issue tracker credentials secret 116 SecretJenkinsPipelineIssueCredentials = "jx-pipeline-issues-" // #nosec 117 118 // ConfigMapExposecontroller the name of the ConfigMap with the Exposecontroller configuration 119 ConfigMapExposecontroller = "exposecontroller" 120 121 // ConfigMapIngressConfig the new name of the ConfigMap with the Exposecontroller configuration 122 ConfigMapIngressConfig = "ingress-config" 123 124 // ConfigMapJenkinsX the name of the ConfigMap with the Jenkins configuration 125 ConfigMapJenkinsX = "jenkins" 126 127 // ConfigMapJenkinsPodTemplates is the ConfigMap containing all the Pod Templates available 128 ConfigMapJenkinsPodTemplates = "jenkins-x-pod-templates" 129 130 // ConfigMapJenkinsTeamController is the ConfigMap containing the TeamController config files 131 ConfigMapJenkinsTeamController = "jenkins-x-team-controller" 132 133 // ConfigMapJenkinsDockerRegistry is the ConfigMap containing the Docker Registry configuration 134 ConfigMapJenkinsDockerRegistry = "jenkins-x-docker-registry" 135 136 // ConfigMapJenkinsDockerRegistryMirror is the ConfigMap containing the Docker Registry Mirror configuration 137 ConfigMapJenkinsDockerRegistryMirror = "jenkins-x-docker-registry-mirror" 138 139 // ConfigMapNameJXInstallConfig is the ConfigMap containing the jx installation's CA and server url. Used by jx login 140 ConfigMapNameJXInstallConfig = "jx-install-config" 141 142 // LocalHelmRepoName is the default name of the local chart repository where CI/CD releases go to 143 LocalHelmRepoName = "releases" 144 145 // DeploymentTektonController the name of the Deployment for the Tekton Pipeline controller 146 DeploymentTektonController = "tekton-pipelines-controller" 147 148 // DeploymentExposecontrollerService the name of the Deployment for the Exposecontroller Service 149 DeploymentExposecontrollerService = "exposecontroller-service" 150 151 // DeploymentProwBuild the name of the Deployment for the Prow webhook engine 152 DeploymentProwBuild = "prow-build" 153 154 DefaultEnvironmentGitRepoURL = "https://github.com/jenkins-x/default-environment-charts.git" 155 156 DefaultOrganisationGitRepoURL = "https://github.com/jenkins-x/default-organisation.git" 157 158 // AnnotationTitle the human readable name of a resource which can include mixed case, spaces and punctuation 159 AnnotationTitle = "title" 160 161 // AnnotationDescription the tooltip / texual description of an resource 162 AnnotationDescription = "description" 163 164 // LabelGitSync to indicate whether or not to sync this resource to GitOps 165 LabelGitSync = "jenkins.io/gitSync" 166 167 // LabelKind to indicate the kind of auth, such as Git or Issue 168 LabelKind = "jenkins.io/kind" 169 170 // ValueKindAddon an addon auth secret/credentials 171 ValueKindAddon = "addon" 172 173 // ValueKindChat a chat auth secret/credentials 174 ValueKindChat = "chat" 175 176 // ValueKindCVE an CVS App secret/credentials 177 ValueKindCVE = "cve" 178 179 // ValueKindEnvironmentRole to indicate a Role which maps to an EnvironmentRoleBinding 180 ValueKindEnvironmentRole = "EnvironmentRole" 181 182 // ValueKindGit a git auth secret/credentials 183 ValueKindGit = "git" 184 185 // ValueKindIssue an issue auth secret/credentials 186 ValueKindIssue = "issue" 187 188 // ValueKindChartmuseum a chartmuseum auth secret/credentials 189 ValueKindChartmuseum = "chartmuseum" 190 191 // ValueKindJenkins an Jenkins App secret/credentials 192 ValueKindJenkins = "jenkins" 193 194 // ValueKindCVE an addon auth PipelineEvent 195 ValueKindPipelineEvent = "PipelineEvent" 196 197 // ValueKindPodTemplate a PodTemplate in a ConfigMap 198 ValueKindPodTemplate = "podTemplate" 199 200 // ValueKindPodTemplateXML a PodTemplate XML in a ConfigMap 201 ValueKindPodTemplateXML = "podTemplateXml" 202 203 // ValueKindCVE an addon auth PipelineEvent 204 ValueKindRelease = "Release" 205 206 // ValueKindEditNamespace for edit namespace 207 ValueKindEditNamespace = "editspace" 208 209 // LabelServiceKind the label to indicate the auto Server's Kind 210 LabelServiceKind = "jenkins.io/service-kind" 211 212 // LabelGithubAppOwner the label to indicate the owner of a repository for github app token secrets 213 LabelGithubAppOwner = "jenkins.io/githubapp-owner" 214 215 // LabelCreatedBy indicates the service that created this resource 216 LabelCreatedBy = "jenkins.io/created-by" 217 218 // LabelPodTemplate the name of the pod template for a DevPod 219 LabelPodTemplate = "jenkins.io/pod_template" 220 221 // LabelDevPodName the name of a dev pod 222 LabelDevPodName = "jenkins.io/devpod" 223 224 // LabelDevPodUsername the user name owner of the DeVPod 225 LabelDevPodUsername = "jenkins.io/devpod_user" 226 227 // LabelDevPodGitPrefix used to label a devpod with the repository host, owner, repo 228 LabelDevPodGitPrefix = "jenkins.io/repo" 229 230 // LabelUsername the user name owner of a namespace or resource 231 LabelUsername = "jenkins.io/user" 232 233 // ValueCreatedByJX for resources created by the Jenkins X CLI 234 ValueCreatedByJX = "jx" 235 236 // LabelCredentialsType the kind of jenkins credential for a secret 237 LabelCredentialsType = "jenkins.io/credentials-type" 238 239 // ValueCredentialTypeUsernamePassword for user password credential secrets 240 ValueCredentialTypeUsernamePassword = "usernamePassword" 241 242 // ValueCredentialTypeSecretFile for secret files 243 ValueCredentialTypeSecretFile = "secretFile" 244 245 // LabelTeam indicates the team name an environment belongs to 246 LabelTeam = "team" 247 248 // LabelEnvironment indicates the name of the environment 249 LabelEnvironment = "env" 250 251 // LabelValueDevEnvironment is the value of the LabelTeam label for Development environments (system namespace) 252 LabelValueDevEnvironment = "dev" 253 254 // LabelValueThisEnvironment is the value of the LabelTeam label for the current environment in remote clusters 255 LabelValueThisEnvironment = "this" 256 257 // LabelJobKind the kind of job 258 LabelJobKind = "jenkins.io/job-kind" 259 260 // ValueJobKindPostPreview 261 ValueJobKindPostPreview = "post-preview-step" 262 263 // AnnotationURL indicates a service/server's URL 264 AnnotationURL = "jenkins.io/url" 265 266 // AnnotationExpose used to expose service using exposecontroller 267 AnnotationExpose = "fabric8.io/expose" 268 269 // AnnotationIngress tells exposecontroller to annotate generated ingress rule with values 270 AnnotationIngress = "fabric8.io/ingress.annotations" 271 272 // AnnotationExposePort indicates to the exposecontroller which service port to expose 273 //in case a service has multiple prots 274 AnnotationExposePort = "fabric8.io/exposePort" 275 276 // AnnotationName indicates a service/server's textual name (can be mixed case, contain spaces unlike Kubernetes resources) 277 AnnotationName = "jenkins.io/name" 278 279 // AnnotationCredentialsDescription the description text for a Credential on a Secret 280 AnnotationCredentialsDescription = "jenkins.io/credentials-description" 281 282 // AnnotationWorkingDir the working directory, such as for a DevPod 283 AnnotationWorkingDir = "jenkins.io/working-dir" 284 // AnnotationLocalDir the local directory that is sync'd to the DevPod 285 AnnotationLocalDir = "jenkins.io/local-dir" 286 // AnnotationGitURLs the newline separated list of git URLs of the DevPods 287 AnnotationGitURLs = "jenkins.io/git-urls" 288 // AnnotationGitReportState used to annotate what state has been reported to git 289 AnnotationGitReportState = "jenkins.io/git-report-state" 290 // AnnotationGitReportRunningStages used to annotate what stages were last reported to git as running 291 AnnotationGitReportRunningStages = "jenkins.io/git-report-running-stages" 292 293 // AnnotationIsDefaultStorageClass used to indicate a storageclass is default 294 AnnotationIsDefaultStorageClass = "storageclass.kubernetes.io/is-default-class" 295 296 // AnnotationReleaseName is the name of the annotation that stores the release name in the preview environment 297 AnnotationReleaseName = "jenkins.io/chart-release" 298 299 // SecretDataUsername the username in a Secret/Credentials 300 SecretDataUsername = "username" 301 302 // SecretDataPassword the password in a Secret/Credentials 303 SecretDataPassword = "password" 304 305 // SecretBasicAuth the name for the Jenkins X basic auth secret 306 SecretBasicAuth = "jx-basic-auth" // #nosec 307 308 // JenkinsAdminApiToken the API token 309 JenkinsAdminApiToken = "jenkins-admin-api-token" 310 311 // JenkinsAdminUserField the admin user name 312 JenkinsAdminUserField = "jenkins-admin-user" 313 314 // JenkinsAdminPasswordField the password field 315 JenkinsAdminPasswordField = "jenkins-admin-password" 316 317 // JenkinsBearTokenField the bearer token 318 JenkinsBearTokenField = "jenkins-bearer-token" 319 320 AUTH = "auth" 321 322 // Region stores the cloud region the cluster is installed on 323 Region = "region" 324 325 // Zone stores the cloud zone of the install 326 Zone = "zone" 327 328 // ProjectID stores the project ID used to install the cluster (a GKE thing mostly) 329 ProjectID = "projectID" 330 331 // ClusterName stores the name of the cluster that is created 332 ClusterName = "clusterName" 333 334 // KubeProvider stores the kubernetes provider name 335 KubeProvider = "kubeProvider" 336 ) 337 338 var ( 339 AddonCharts = map[string]string{ 340 "ambassador": ChartAmbassador, 341 "anchore": ChartAnchore, 342 DefaultFlaggerReleaseName: ChartFlagger, 343 "gitea": ChartGitea, 344 "istio": ChartIstio, 345 "kubeless": ChartKubeless, 346 "prometheus": "stable/prometheus", 347 "grafana": "stable/grafana", 348 "jx-build-templates": "jenkins-x/jx-build-templates", 349 DefaultProwReleaseName: ChartProw, 350 DefaultKnativeBuildReleaseName: ChartKnativeBuild, 351 DefaultTektonReleaseName: ChartTekton, 352 DefaultSsoDexReleaseName: ChartSsoDex, 353 DefaultSsoOperatorReleaseName: ChartSsoOperator, 354 DefaultVaultOperatorReleaseName: ChartVaultOperator, 355 } 356 357 AddonServices = map[string]string{ 358 "anchore": "anchore-anchore-engine", 359 "pipeline-events": "jx-pipeline-events-elasticsearch-client", 360 "grafana": "grafana", 361 } 362 )