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
6a70d7c0
Commit
6a70d7c0
authored
Jul 09, 2019
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab-ce master
parents
33f79100
b9b60224
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
9 deletions
+9
-9
qa/qa/runtime/env.rb
qa/qa/runtime/env.rb
+2
-2
qa/qa/service/kubernetes_cluster.rb
qa/qa/service/kubernetes_cluster.rb
+7
-7
No files found.
qa/qa/runtime/env.rb
View file @
6a70d7c0
...
...
@@ -179,8 +179,8 @@ module QA
ENV
.
fetch
(
"GCLOUD_ACCOUNT_EMAIL"
)
end
def
gcloud_
zone
ENV
.
fetch
(
'GCLOUD_
ZONE
'
)
def
gcloud_
region
ENV
.
fetch
(
'GCLOUD_
REGION
'
)
end
def
has_gcloud_credentials?
...
...
qa/qa/service/kubernetes_cluster.rb
View file @
6a70d7c0
...
...
@@ -28,17 +28,17 @@ module QA
create
#{
cluster_name
}
#{
auth_options
}
--enable-basic-auth
--
zone
#{
Runtime
::
Env
.
gcloud_zone
}
--
region
#{
Runtime
::
Env
.
gcloud_region
}
&& gcloud container clusters
get-credentials
--
zone
#{
Runtime
::
Env
.
gcloud_zone
}
--
region
#{
Runtime
::
Env
.
gcloud_region
}
#{
cluster_name
}
CMD
@api_url
=
`kubectl config view --minify -o jsonpath='{.clusters[].cluster.server}'`
@admin_user
=
"
#{
cluster_name
}
-admin"
master_auth
=
JSON
.
parse
(
`gcloud container clusters describe
#{
cluster_name
}
--
zone
#{
Runtime
::
Env
.
gcloud_zone
}
--format 'json(masterAuth.username, masterAuth.password)'`
)
master_auth
=
JSON
.
parse
(
`gcloud container clusters describe
#{
cluster_name
}
--
region
#{
Runtime
::
Env
.
gcloud_region
}
--format 'json(masterAuth.username, masterAuth.password)'`
)
shell
<<~
CMD
.
tr
(
"
\n
"
,
' '
)
kubectl config set-credentials
#{
@admin_user
}
--username
#{
master_auth
[
'masterAuth'
][
'username'
]
}
...
...
@@ -66,7 +66,7 @@ module QA
def
remove!
shell
<<~
CMD
.
tr
(
"
\n
"
,
' '
)
gcloud container clusters delete
--
zone
#{
Runtime
::
Env
.
gcloud_zone
}
--
region
#{
Runtime
::
Env
.
gcloud_region
}
#{
cluster_name
}
--quiet --async
CMD
...
...
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