Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
40c6128b
Commit
40c6128b
authored
Oct 02, 2017
by
Alessio Caiazza
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix broken certificate-authority-data with kubectl >= 1.8.0
parent
f1b8d79f
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
3 deletions
+8
-3
changelogs/unreleased/fix-kubectl-180.yml
changelogs/unreleased/fix-kubectl-180.yml
+5
-0
lib/gitlab/kubernetes.rb
lib/gitlab/kubernetes.rb
+1
-1
spec/fixtures/config/kubeconfig.yml
spec/fixtures/config/kubeconfig.yml
+1
-1
spec/models/project_services/kubernetes_service_spec.rb
spec/models/project_services/kubernetes_service_spec.rb
+1
-1
No files found.
changelogs/unreleased/fix-kubectl-180.yml
0 → 100644
View file @
40c6128b
---
title
:
'
Kubernetes
integration:
ensure
v1.8.0
compatibility'
merge_request
:
14635
author
:
type
:
fixed
lib/gitlab/kubernetes.rb
View file @
40c6128b
...
...
@@ -113,7 +113,7 @@ module Gitlab
def
kubeconfig_embed_ca_pem
(
config
,
ca_pem
)
cluster
=
config
.
dig
(
:clusters
,
0
,
:cluster
)
cluster
[
:'certificate-authority-data'
]
=
Base64
.
encode64
(
ca_pem
)
cluster
[
:'certificate-authority-data'
]
=
Base64
.
strict_
encode64
(
ca_pem
)
end
end
end
spec/fixtures/config/kubeconfig.yml
View file @
40c6128b
...
...
@@ -4,7 +4,7 @@ clusters:
-
name
:
gitlab-deploy
cluster
:
server
:
https://kube.domain.com
certificate-authority-data
:
"
UEVN
\n
"
certificate-authority-data
:
"
UEVN"
contexts
:
-
name
:
gitlab-deploy
context
:
...
...
spec/models/project_services/kubernetes_service_spec.rb
View file @
40c6128b
...
...
@@ -208,7 +208,7 @@ describe KubernetesService, :use_clean_rails_memory_store_caching do
config
.
dig
(
'users'
,
0
,
'user'
)[
'token'
]
=
'token'
config
.
dig
(
'contexts'
,
0
,
'context'
)[
'namespace'
]
=
namespace
config
.
dig
(
'clusters'
,
0
,
'cluster'
)[
'certificate-authority-data'
]
=
Base64
.
encode64
(
'CA PEM DATA'
)
Base64
.
strict_
encode64
(
'CA PEM DATA'
)
YAML
.
dump
(
config
)
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment