Revert Helm version bump
This commit is contained in:
parent
623940bfa1
commit
0ddff09385
|
@ -8,7 +8,7 @@ module Clusters
|
|||
|
||||
# This is required for helm version <= 2.10.x in order to support
|
||||
# Setting up CRDs
|
||||
ISTIO_CRDS = 'http://cabnetworks.net/triggermesh-charts/istio-crds.yaml'.freeze
|
||||
ISTIO_CRDS = 'https://storage.googleapis.com/triggermesh-charts/istio-crds.yaml'.freeze
|
||||
|
||||
self.table_name = 'clusters_applications_knative'
|
||||
|
||||
|
@ -37,10 +37,15 @@ module Clusters
|
|||
chart: chart,
|
||||
files: files,
|
||||
repository: REPOSITORY,
|
||||
setargs: args
|
||||
setargs: args,
|
||||
script: install_script
|
||||
)
|
||||
end
|
||||
|
||||
def install_script
|
||||
['/usr/bin/kubectl', 'apply', '-f', ISTIO_CRDS]
|
||||
end
|
||||
|
||||
def client
|
||||
cluster&.platform_kubernetes&.kubeclient&.core_client
|
||||
end
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
module Gitlab
|
||||
module Kubernetes
|
||||
module Helm
|
||||
HELM_VERSION = '2.11.0'.freeze
|
||||
HELM_VERSION = '2.7.2'.freeze
|
||||
NAMESPACE = 'gitlab-managed-apps'.freeze
|
||||
SERVICE_ACCOUNT = 'tiller'.freeze
|
||||
CLUSTER_ROLE_BINDING = 'tiller-admin'.freeze
|
||||
|
|
|
@ -17,6 +17,14 @@ module Gitlab
|
|||
apk add -U wget ca-certificates openssl git >/dev/null
|
||||
wget -q -O - https://kubernetes-helm.storage.googleapis.com/helm-v#{Gitlab::Kubernetes::Helm::HELM_VERSION}-linux-amd64.tar.gz | tar zxC /tmp >/dev/null
|
||||
mv /tmp/linux-amd64/helm /usr/bin/
|
||||
|
||||
wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub
|
||||
wget -q https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.28-r0/glibc-2.28-r0.apk
|
||||
apk add glibc-2.28-r0.apk > /dev/null
|
||||
rm glibc-2.28-r0.apk
|
||||
wget -q https://storage.googleapis.com/kubernetes-release/release/v1.11.0/bin/linux/amd64/kubectl
|
||||
chmod +x kubectl
|
||||
mv kubectl /usr/bin/
|
||||
HEREDOC
|
||||
end
|
||||
|
||||
|
|
|
@ -4,9 +4,9 @@ module Gitlab
|
|||
class InstallCommand
|
||||
include BaseCommand
|
||||
|
||||
attr_reader :name, :files, :chart, :version, :repository, :setargs
|
||||
attr_reader :name, :files, :chart, :version, :repository, :setargs, :script
|
||||
|
||||
def initialize(name:, chart:, files:, rbac:, version: nil, repository: nil, setargs: nil)
|
||||
def initialize(name:, chart:, files:, rbac:, version: nil, repository: nil, setargs: nil, script: nil)
|
||||
@name = name
|
||||
@chart = chart
|
||||
@version = version
|
||||
|
@ -14,6 +14,7 @@ module Gitlab
|
|||
@files = files
|
||||
@repository = repository
|
||||
@setargs = setargs
|
||||
@script = script
|
||||
end
|
||||
|
||||
def generate_script
|
||||
|
@ -21,7 +22,8 @@ module Gitlab
|
|||
init_command,
|
||||
repository_command,
|
||||
repository_update_command,
|
||||
script_command
|
||||
script_command,
|
||||
install_command
|
||||
].compact.join("\n")
|
||||
end
|
||||
|
||||
|
@ -43,12 +45,18 @@ module Gitlab
|
|||
'helm repo update >/dev/null' if repository
|
||||
end
|
||||
|
||||
def script_command
|
||||
def install_command
|
||||
command = ['helm', 'install', chart] + install_command_flags
|
||||
|
||||
command.shelljoin + " >/dev/null\n"
|
||||
end
|
||||
|
||||
def script_command
|
||||
unless script.nil?
|
||||
script.shelljoin + " >/dev/null\n"
|
||||
end
|
||||
end
|
||||
|
||||
def install_command_flags
|
||||
name_flag = ['--name', name]
|
||||
namespace_flag = ['--namespace', Gitlab::Kubernetes::Helm::NAMESPACE]
|
||||
|
|
|
@ -7,8 +7,16 @@ shared_examples 'helm commands' do
|
|||
echo http://mirror.clarkson.edu/alpine/v$ALPINE_VERSION/main >> /etc/apk/repositories
|
||||
echo http://mirror1.hs-esslingen.de/pub/Mirrors/alpine/v$ALPINE_VERSION/main >> /etc/apk/repositories
|
||||
apk add -U wget ca-certificates openssl git >/dev/null
|
||||
wget -q -O - https://kubernetes-helm.storage.googleapis.com/helm-v2.11.0-linux-amd64.tar.gz | tar zxC /tmp >/dev/null
|
||||
wget -q -O - https://kubernetes-helm.storage.googleapis.com/helm-v2.7.2-linux-amd64.tar.gz | tar zxC /tmp >/dev/null
|
||||
mv /tmp/linux-amd64/helm /usr/bin/
|
||||
|
||||
wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub
|
||||
wget -q https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.28-r0/glibc-2.28-r0.apk
|
||||
apk add glibc-2.28-r0.apk > /dev/null
|
||||
rm glibc-2.28-r0.apk
|
||||
wget -q https://storage.googleapis.com/kubernetes-release/release/v1.11.0/bin/linux/amd64/kubectl
|
||||
chmod +x kubectl
|
||||
mv kubectl /usr/bin/
|
||||
EOS
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue