jx install failed using an on premise Kubernetes cluster

Created on 28 Nov 2019  路  12Comments  路  Source: jenkins-x/jx

Summary

Cannot install Jenkins X to an on premise Kubernetes cluster. Some deployments are not recognised by Kubernetes. I'm trying to integrate it with my on premise Gitea and also with an on premise Docker Registry. I'll also try to use a on premise ChartMuseum, but I think jx will deploy it for me. I can try to deploy it if necessary, and then config jx to use it.

I also have problems downloading latest version of helm.

Steps to reproduce the behavior

  • Download the latest version of jx (as Official Documentation says)
 curl -L "https://github.com/jenkins-x/jx/releases/download/$(curl --silent https://api.github.com/repos/jenkins-x/jx/releases/latest | jq -r '.tag_name')/jx-linux-amd64.tar.gz" | tar xzv "jx"
  • set $KUBECONFIG
  • run the following command:
jx install --provider=kubernetes --on-premise --git-provider-url=<URL-to-on-premise-Gitea> --git-provider-kind=gitea --static-jenkins --git-username=jenkins --git-api-token=<token-configured-with-gitea-for-user-jenkins>

Expected behavior

  • jx is successfully installed and ready to go.

Actual behavior

Running the mentioned command without helm at $PATH

Installing helm
Downloading https://storage.googleapis.com/kubernetes-helm/helm-v3.0.0-linux-amd64.tar.gz to $HOME/.jx/bin/helm.tgz...
error: installing helm binaries: error installing helm: Unable to download file $HOME/.jx/bin/helm.tgz from https://storage.googleapis.com/kubernetes-helm/helm-v3.0.0-linux-amd64.tar.gz due to: download of https://storage.googleapis.com/kubernetes-helm/helm-v3.0.0-linux-amd64.tar.gz failed with return code 404

Trying with the latest one (helm 3 binary downloaded from official page):

WARNING:
retrying after error:failed to run 'helm init --client-only' command in directory '', output: 'Error: unknown flag: --client-only'
WARNING:
retrying after error:failed to run 'helm init --client-only' command in directory '', output: 'Error: unknown flag: --client-only'
FATAL: helm init failed: after 3 attempts, last error: failed to run 'helm init --client-only' command in directory '', output: 'Error: unknown flag: --client-only'

In case helm 2 is installed (latest), I can follow more steps of jx. The last one asks for the API Token and if I want to use my Git server as the pipelines Git server. After that, it is stopped with this output:

<... lots of secrets, configmaps, clusterroles, deployments, etc. created successfully...>
unable to recognize "/tmp/helm-template-workdir-850806553/jenkins-x/output/namespaces/jx/jenkins-x-platform/charts/chartmuseum/templates/part0-deployment.yaml": no matches for kind "Deployment" in version "extensions/v1beta1"
unable to recognize "/tmp/helm-template-workdir-850806553/jenkins-x/output/namespaces/jx/jenkins-x-platform/charts/docker-registry/templates/part0-deployment.yaml": no matches for kind "Deployment" in version "extensions/v1beta1"
unable to recognize "/tmp/helm-template-workdir-850806553/jenkins-x/output/namespaces/jx/jenkins-x-platform/charts/heapster/templates/part0-deployment.yaml": no matches for kind "Deployment" in version "extensions/v1beta1"
unable to recognize "/tmp/helm-template-workdir-850806553/jenkins-x/output/namespaces/jx/jenkins-x-platform/charts/jenkins/templates/part0-jenkins-master-deployment.yaml": no matches for kind "Deployment" in version "extensions/v1beta1"
unable to recognize "/tmp/helm-template-workdir-850806553/jenkins-x/output/namespaces/jx/jenkins-x-platform/charts/nexus/templates/part0-deployment.yaml": no matches for kind "Deployment" in version "extensions/v1beta1"'

Jx version

The output of jx version is:

NAME               VERSION
jx                 2.0.1029
Kubernetes cluster v1.16.3
kubectl            v1.16.3
git                2.7.4
Operating System   Ubuntu 16.04.6 LTS


verifying packages
? A local Jenkins X versions repository already exists, pulling the latest: Yes
error: package git is an old version 2.7.4. The version stream requires at least 2.15.0

If necessary, I will upgrade Ubuntu to 18.04.3 LTS. I can also upgrade git to 2.15 using ppa:git-core/ppa repo. This is not the same git as Gitea (gitea:latest uses git 2.22.0)

Jenkins type

  • [ ] Serverless Jenkins X Pipelines (Tekton + Prow)
  • [X] Classic Jenkins

Kubernetes cluster


I have an on premise Kubernetes cluster (following KTHW). I'm using the latest version of Kubernetes and jx. I have deployed some pods (Gitea, sonobuoy, Docker Registry, apache, nginx, etc.).

I passed all sonobuoytests (running jx compliance run and sonobuoy run) except the following ones:

[sig-api-machinery] Aggregator Should be able to support the 1.10 Sample API Server using the current Aggregator [Conformance]

Operating system / Environment

cat /etc/os-release

The output is:

NAME="Ubuntu"
VERSION="16.04.6 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.6 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
VERSION_CODENAME=xenial
UBUNTU_CODENAME=xenial

arehelm arejenkins arekubernetes kinbug lifecyclrotten prioritcritical

Most helpful comment

Hi @deanesmith and @daveconde

Do you have any news about this issue? I'm still not able to deploy jx

Thank you so much,

All 12 comments

cc @deanesmith

The same with version 2.0.1074

I was reading the logs, and why are they extensions/v1beta1 if Deployments are apps/v1? Is this something that we need to fix when downloading the local Jenkins X cloud environments repository?

Hi @deanesmith and @daveconde

Do you have any news about this issue? I'm still not able to deploy jx

Thank you so much,

Still happening the same with 2.0.1200

What I'm seeing is that is failing during the installation of the platform. I'll open an issue to them.

This is my actual configuration:

NAME               VERSION
jx                 2.0.1200
Kubernetes cluster v1.16.3
kubectl            v1.16.3
helm client        v2.16.1+gbbdfe5e
helm server        v2.16.1+gbbdfe5e
git                2.17.1
Operating System   Ubuntu 18.04.3 LTS

/etc/os-release

NAME="Ubuntu"
VERSION="18.04.3 LTS (Bionic Beaver)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 18.04.3 LTS"
VERSION_ID="18.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=bionic
UBUNTU_CODENAME=bionic

Still happening the same with 2.0.1200

What I'm seeing is that is failing during the installation of the platform. I'll open an issue to them.

This is my actual configuration:

NAME               VERSION
jx                 2.0.1200
Kubernetes cluster v1.16.3
kubectl            v1.16.3
helm client        v2.16.1+gbbdfe5e
helm server        v2.16.1+gbbdfe5e
git                2.17.1
Operating System   Ubuntu 18.04.3 LTS

/etc/os-release

NAME="Ubuntu"
VERSION="18.04.3 LTS (Bionic Beaver)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 18.04.3 LTS"
VERSION_ID="18.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=bionic
UBUNTU_CODENAME=bionic

I was having issues with this and I believe got it working with k8s version 1.15. If you can go down a version, try that and let me know if it works

I'll try it, but I will need some time.

Is there a way to use my own docker registry (from a pod/svc) and also chartmuseum? I have my own pods running and it would be great to use them. Otherwise I need to migrate the data.

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close.
Provide feedback via https://jenkins-x.io/community.
/lifecycle stale

I have this problem at the moment too. This is my JenkinsX version
Version 2.1.98 Commit a6747c4 Build date 2020-07-09T15:16:45Z Go version 1.13.8 Git tree state clean
It cannot be that official sources are used which do not work. When will there be a solution?

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close.
Provide feedback via https://jenkins-x.io/community.
/lifecycle rotten

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.
Provide feedback via https://jenkins-x.io/community.
/close

@jenkins-x-bot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.
Provide feedback via https://jenkins-x.io/community.
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the jenkins-x/lighthouse repository.

Was this page helpful?
0 / 5 - 0 ratings