Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kubespray
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Mirror
Kubespray
Commits
f26e16bf
Commit
f26e16bf
authored
7 years ago
by
Shravan Papanaidu
Browse files
Options
Downloads
Patches
Plain Diff
kubectl get pods from 'test' namespace as the pods were created in 'test' ns
parent
6c220e4e
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/testcases/030_check-network.yml
+4
-4
4 additions, 4 deletions
tests/testcases/030_check-network.yml
with
4 additions
and
4 deletions
tests/testcases/030_check-network.yml
+
4
−
4
View file @
f26e16bf
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
-
name
:
Wait for pods to be ready
-
name
:
Wait for pods to be ready
shell
:
"
{{bin_dir}}/kubectl
get
pods"
shell
:
"
{{bin_dir}}/kubectl
get
pods
-n
test
"
register
:
pods
register
:
pods
until
:
until
:
-
'
"ContainerCreating"
not
in
pods.stdout'
-
'
"ContainerCreating"
not
in
pods.stdout'
...
@@ -25,18 +25,18 @@
...
@@ -25,18 +25,18 @@
no_log
:
true
no_log
:
true
-
name
:
Get pod names
-
name
:
Get pod names
shell
:
"
{{bin_dir}}/kubectl
get
pods
-o
json"
shell
:
"
{{bin_dir}}/kubectl
get
pods
-n
test
-o
json"
register
:
pods
register
:
pods
no_log
:
true
no_log
:
true
-
name
:
Get hostnet pods
-
name
:
Get hostnet pods
command
:
"
{{bin_dir}}/kubectl
get
pods
-o
command
:
"
{{bin_dir}}/kubectl
get
pods
-n
test
-o
jsonpath='{range
.items[?(.spec.hostNetwork)]}{.metadata.name}
{.status.podIP}
{.status.containerStatuses}
{end}'"
jsonpath='{range
.items[?(.spec.hostNetwork)]}{.metadata.name}
{.status.podIP}
{.status.containerStatuses}
{end}'"
register
:
hostnet_pods
register
:
hostnet_pods
no_log
:
true
no_log
:
true
-
name
:
Get running pods
-
name
:
Get running pods
command
:
"
{{bin_dir}}/kubectl
get
pods
-o
command
:
"
{{bin_dir}}/kubectl
get
pods
-n
test
-o
jsonpath='{range
.items[?(.status.phase==
\"
Running
\"
)]}{.metadata.name}
{.status.podIP}
{.status.containerStatuses}
{end}'"
jsonpath='{range
.items[?(.status.phase==
\"
Running
\"
)]}{.metadata.name}
{.status.podIP}
{.status.containerStatuses}
{end}'"
register
:
running_pods
register
:
running_pods
no_log
:
true
no_log
:
true
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment