When following the documentation about how to install Jenkins X with a different git server (GitLab in my case) the installation process asked me if I want to use my GitHub user name. When I input no the installation process asks me for an other GitHub username even though I used jx install --no-default-environments like in the documentation
I let it slide and went through the rest of the process just like in the documentation, so I added an other git server following this part of the documentation. But when I tried to jx create env staging the creation process still used GitHub as a git server
jx install --no-default-environments
jx create git server gitlab https://gitlab.com/
jx create git token -n gitlab user
jx create env staging
The output of jx version is:
$ jx version
Using helmBinary helm with feature flag: none
NAME VERSION
jx 1.3.541
jenkins x platform 0.0.2871
Kubernetes cluster v1.10.3
kubectl v1.12.2
helm client v2.9.1+g20adb27
helm server v2.10.0+g9ad53aa
git git version 2.17.1
AWS provisioned using KOPS
Kubuntu 18.04
When installing Jenkins-X I'd expect to not being asked about any git server and let me setup my git server later on just like in the documentation.
It'd be a lot better if you could just pick a git server during the installation process from my added git servers list
jx install --no-default-environments:
Using helmBinary helm with feature flag: none
Namespace jx created
? Cloud Provider aws
Storing the kubernetes provider aws in the TeamSettings
Updated the team settings in namespace jx
Git configured for user: David Alonim and email [email protected]
Using helm2
Configuring tiller
Tiller Deployment is running in namespace kube-system
existing ingress controller found, no need to install a new one
Waiting for external loadbalancer to be created and update the nginx-ingress-controller service in kube-system namespace
External loadbalancer created
Waiting to find the external host name of the ingress controller Service in namespace kube-system with name jxing-nginx-ingress-controller
On AWS we recommend using a custom DNS name to access services in your Kubernetes cluster to ensure you can use all of your Availability Zones
If you do not have a custom DNS name you can use yet you can register a new one here: https://console.aws.amazon.com/route53/home?#DomainRegistration:
? Would you like to register a wildcard DNS ALIAS to point at this ELB address? Yes
? Your custom DNS name: example.com
About to insert/update DNS CNAME record into HostedZone /hostedzone/<id> with wildcard *.example.com pointing to someelb.com
Updated HostZone ID /hostedzone/<id> successfully
nginx ingress controller installed and configured
Lets set up a Git username and API token to be able to perform CI/CD
? Do you wish to use masterdrdark as the GitHub username for CI/CD pipelines: No
? GitHub username for CI/CD pipelines:
jx create git server gitlab https://gitlab.com/:
Added Git server gitlab for URL https://gitlab.com/
GitService gitlab created in namespace jx for URL https://gitlab.com/
Ensured we have a GitService called gitlab for URL https://gitlab.com/ in namespace jx
jx create git token -n gitlab user:
already has GitService gitlab in namespace jx for URL https://gitlab.com/
Ensured we have a GitService called gitlab for URL https://gitlab.com/ in namespace jx
Please generate an API Token for gitlab server gitlab
Click this URL https://gitlab.com/profile/personal_access_tokens
Then COPY the token and enter in into the form below:
? API Token: ********************
Created user user API Token for Git server gitlab at https://gitlab.com/
jx create env staging:
? Label: Staging
? Namespace: jx-staging
? Domain: example.com
? Cluster URL: mycluster.com
? Promotion Strategy: Manual
? We will now create a Git repository to store your staging environment, ok? : Yes
Using Git provider GitHub at https://github.com
? Do you wish to use masterdrdark as the Git user name? No
? Git user name?
What if you add --git-provider-url=https://gitlab.com to the jx create env command?
That works, so either edit the docs or add the option to pick a git server during installation and env creation :)
Thanks for the issue @masterdrdark and the answer @beebird! Docs are updated but let us know if it can be clearer / improved https://github.com/jenkins-x/jx-docs/commit/6f337ab6d7d6ee172e0d2cdf8fa18d0b3263f5fe
@rawlingsj should this be fixed? I still get asked to provide a GitHub user name even when using jx install --no-default-environments.
I am choosing Cloud Provider kubernetes in the wizard.
...
nginx ingress controller installed and configured
Lets set up a Git user name and API token to be able to perform CI/CD
Creating a local Git user for GitHub server
? GitHub user name:
My jx version:
NAME VERSION
jx 2.0.67
Kubernetes cluster v1.10.11
kubectl v1.14.1
helm client Client: v2.13.1+g618447c
git git version 2.21.0
Operating System Mac OS X 10.14.4 build 18E226
I am referring to https://jenkins-x.io/developing/git/#using-a-different-git-provider-for-environments
Most helpful comment
@rawlingsj should this be fixed? I still get asked to provide a GitHub user name even when using
jx install --no-default-environments.I am choosing
Cloud Provider kubernetesin the wizard.My jx version:
I am referring to https://jenkins-x.io/developing/git/#using-a-different-git-provider-for-environments