Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
cf27de61
Commit
cf27de61
authored
Apr 20, 2015
by
Victor Marmol
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #7035 from smarterclayton/turn_down_kubelet_for_what
Tone down kubelet logs for already run containers
parents
446f3499
9e879249
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
kubelet.go
pkg/kubelet/kubelet.go
+3
-3
No files found.
pkg/kubelet/kubelet.go
View file @
cf27de61
...
@@ -1002,14 +1002,14 @@ func shouldContainerBeRestarted(container *api.Container, pod *api.Pod, podStatu
...
@@ -1002,14 +1002,14 @@ func shouldContainerBeRestarted(container *api.Container, pod *api.Pod, podStatu
// Check RestartPolicy for dead container.
// Check RestartPolicy for dead container.
if
len
(
resultStatus
)
>
0
{
if
len
(
resultStatus
)
>
0
{
if
pod
.
Spec
.
RestartPolicy
==
api
.
RestartPolicyNever
{
if
pod
.
Spec
.
RestartPolicy
==
api
.
RestartPolicyNever
{
glog
.
Infof
(
"Already ran container %q of pod %q, do nothing"
,
container
.
Name
,
podFullName
)
glog
.
V
(
4
)
.
Infof
(
"Already ran container %q of pod %q, do nothing"
,
container
.
Name
,
podFullName
)
return
false
return
false
}
}
if
pod
.
Spec
.
RestartPolicy
==
api
.
RestartPolicyOnFailure
{
if
pod
.
Spec
.
RestartPolicy
==
api
.
RestartPolicyOnFailure
{
// Check the exit code of last run. Note: This assumes the result is sorted
// Check the exit code of last run. Note: This assumes the result is sorted
// by the created time in reverse order.
// by the created time in reverse order.
if
resultStatus
[
0
]
.
State
.
Termination
.
ExitCode
==
0
{
if
resultStatus
[
0
]
.
State
.
Termination
.
ExitCode
==
0
{
glog
.
Infof
(
"Already successfully ran container %q of pod %q, do nothing"
,
container
.
Name
,
podFullName
)
glog
.
V
(
4
)
.
Infof
(
"Already successfully ran container %q of pod %q, do nothing"
,
container
.
Name
,
podFullName
)
return
false
return
false
}
}
}
}
...
@@ -1264,7 +1264,7 @@ func (kl *Kubelet) syncPod(pod *api.Pod, mirrorPod *api.Pod, runningPod kubecont
...
@@ -1264,7 +1264,7 @@ func (kl *Kubelet) syncPod(pod *api.Pod, mirrorPod *api.Pod, runningPod kubecont
if
err
!=
nil
{
if
err
!=
nil
{
glog
.
Errorf
(
"Couldn't make a ref to pod %q: '%v'"
,
podFullName
,
err
)
glog
.
Errorf
(
"Couldn't make a ref to pod %q: '%v'"
,
podFullName
,
err
)
}
}
glog
.
Infof
(
"Creating pod infra container for %q"
,
podFullName
)
glog
.
V
(
4
)
.
Infof
(
"Creating pod infra container for %q"
,
podFullName
)
podInfraContainerID
,
err
=
kl
.
createPodInfraContainer
(
pod
)
podInfraContainerID
,
err
=
kl
.
createPodInfraContainer
(
pod
)
// Call the networking plugin
// Call the networking plugin
...
...
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