Comments (3)
I was wondering if/when this would ever come back to bite me... #37
Long story short... "status" as listed by kubectl isn't either pod-phase or reason... it's actually something different... something not addressed directly in the the API from what I saw.
I suspect that Running
isn't actually a "pod status" but actually a "container status". I 100% agree, it's confusing as hell!
// ContainerState holds a possible state of container.
// Only one of its members may be specified.
// If none of them is specified, the default one is ContainerStateWaiting.
type ContainerState struct {
// Details about a waiting container
// +optional
Waiting *ContainerStateWaiting `json:"waiting,omitempty" protobuf:"bytes,1,opt,name=waiting"`
// Details about a running container
// +optional
Running *ContainerStateRunning `json:"running,omitempty" protobuf:"bytes,2,opt,name=running"`
// Details about a terminated container
// +optional
Terminated *ContainerStateTerminated `json:"terminated,omitempty" protobuf:"bytes,3,opt,name=terminated"`
}
There isn't anything that detects "Running" container state right now, and I think changing the "container status" rule would probably would result in behavior that isn't intended (I think changing the already existing rule would result in the pod being flagged for reaping if ANY of the containers in it were "Running" -- like it currently identifies if ANY container in the pod is "terminated" or "waiting"... uhg...
from pod-reaper.
Perhaps the way forward is
- Rename current pod_status rule to pod_status_reason, and change the environment variable to
POD_STATUS_REASON
- Add pod_status_phase rule with environment variable
POD_STATUS_PHASE
from pod-reaper.
Related Issues (20)
- Easier local development HOT 4
- Allow default configuration override with annotations HOT 14
- Log messages not parsed by Stackdriver HOT 4
- Explicit rule enable
- Setup CI/CD outside of docker
- Deployment bug HOT 2
- Schedule doesn't seem to work correctly HOT 7
- Dry run mode HOT 2
- Update Dependencies to use Go Modules HOT 3
- Helm chart HOT 5
- Does pod-reaper act on 1 pod at a time? or all pods simultaneously HOT 10
- Upgrade docker base image to use golang 1.15 HOT 3
- In nonprod, reduce resouces: Reap pod/apps so they don't consume resources on weekend HOT 1
- Docker builds no longer happening automatically HOT 5
- v1beta1 ClusterRole is deprecated in v1.17+, unavailable in v1.22+; Use v1 ClusterRole
- MAX_DURATION option does not count the Pod Status Start time HOT 3
- Split the helm chart into a new repo or Equate the the Helm chart version with the pod-reaper version HOT 19
- Pod reaping strategy HOT 5
- Improve dry run log accuracy
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pod-reaper.