clear up rkl.#619
Conversation
Remove the logic in rkl that manages resources on a per-container basis and the logic that directly modifies cluster state without going through rks. Signed-off-by: harry <ambition0316@126.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 78e377250a
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| metadata, | ||
| spec: PodSpec { | ||
| containers: vec![container], | ||
| restart_policy: RestartPolicy::Always, |
There was a problem hiding this comment.
Keep single-container pods from restarting unconditionally
The new container-to-pod conversion hard-codes restart_policy to RestartPolicy::Always, which changes rkl run/rkl apply -f <container.yaml> from one-shot container execution into perpetual restart behavior whenever the process exits. This breaks short-lived workloads (for example, migration or batch commands) by turning normal completion into a restart loop; the generated pod should default to Never (or preserve an explicit user policy) to avoid this regression.
Useful? React with 👍 / 👎.
Remove the logic in rkl that manages resources on a per-container basis and the logic that directly modifies cluster state without going through rks.