diff --git a/pkg/common/constants/constants.go b/pkg/common/constants/constants.go index a935a1f53e..6dc948d9d8 100644 --- a/pkg/common/constants/constants.go +++ b/pkg/common/constants/constants.go @@ -61,18 +61,20 @@ const ( DefaultCheServiceAccountName = "che" // OAuth - BitBucketOAuthConfigMountPath = "/che-conf/oauth/bitbucket" - BitBucketOAuthConfigPrivateKeyFileName = "private.key" - BitBucketOAuthConfigConsumerKeyFileName = "consumer.key" - GitHubOAuthConfigMountPath = "/che-conf/oauth/github" - GitHubOAuthConfigClientIdFileName = "id" - GitHubOAuthConfigClientSecretFileName = "secret" - GitLabOAuthConfigMountPath = "/che-conf/oauth/gitlab" - GitLabOAuthConfigClientIdFileName = "id" - GitLabOAuthConfigClientSecretFileName = "secret" - OAuthScmConfiguration = "oauth-scm-configuration" - AccessToken = "access_token" - IdToken = "id_token" + BitBucketOAuthConfigClientIdFileName = "id" + BitBucketOAuthConfigClientSecretFileName = "secret" + BitBucketOAuthConfigMountPath = "/che-conf/oauth/bitbucket" + BitBucketOAuthConfigPrivateKeyFileName = "private.key" + BitBucketOAuthConfigConsumerKeyFileName = "consumer.key" + GitHubOAuthConfigMountPath = "/che-conf/oauth/github" + GitHubOAuthConfigClientIdFileName = "id" + GitHubOAuthConfigClientSecretFileName = "secret" + GitLabOAuthConfigMountPath = "/che-conf/oauth/gitlab" + GitLabOAuthConfigClientIdFileName = "id" + GitLabOAuthConfigClientSecretFileName = "secret" + OAuthScmConfiguration = "oauth-scm-configuration" + AccessToken = "access_token" + IdToken = "id_token" // Labels KubernetesComponentLabelKey = "app.kubernetes.io/component" diff --git a/pkg/deploy/server/server_deployment.go b/pkg/deploy/server/server_deployment.go index b1d977cdfc..9c08788c25 100644 --- a/pkg/deploy/server/server_deployment.go +++ b/pkg/deploy/server/server_deployment.go @@ -330,6 +330,8 @@ func MountBitBucketOAuthConfig(ctx *chetypes.DeployContext, deployment *appsv1.D mountVolumes(deployment, secret, constants.BitBucketOAuthConfigMountPath) mountEnv(deployment, "CHE_OAUTH1_BITBUCKET_CONSUMERKEYPATH", constants.BitBucketOAuthConfigMountPath+"/"+constants.BitBucketOAuthConfigConsumerKeyFileName) mountEnv(deployment, "CHE_OAUTH1_BITBUCKET_PRIVATEKEYPATH", constants.BitBucketOAuthConfigMountPath+"/"+constants.BitBucketOAuthConfigPrivateKeyFileName) + mountEnv(deployment, "CHE_OAUTH2_BITBUCKET_CLIENTID__FILEPATH", constants.BitBucketOAuthConfigMountPath+"/"+constants.BitBucketOAuthConfigClientIdFileName) + mountEnv(deployment, "CHE_OAUTH2_BITBUCKET_CLIENTSECRET__FILEPATH", constants.BitBucketOAuthConfigMountPath+"/"+constants.BitBucketOAuthConfigClientSecretFileName) oauthEndpoint := secret.Annotations[constants.CheEclipseOrgScmServerEndpoint] if oauthEndpoint != "" {