mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-03 09:22:44 +00:00
Log kubelet startup error messages
This commit is contained in:
parent
b3bc741d0d
commit
0eb04cb433
@ -262,7 +262,14 @@ func UnsecuredKubeletConfig(s *options.KubeletServer) (*KubeletConfig, error) {
|
|||||||
// Otherwise, the caller is assumed to have set up the KubeletConfig object and all defaults
|
// Otherwise, the caller is assumed to have set up the KubeletConfig object and all defaults
|
||||||
// will be ignored.
|
// will be ignored.
|
||||||
func Run(s *options.KubeletServer, kcfg *KubeletConfig) error {
|
func Run(s *options.KubeletServer, kcfg *KubeletConfig) error {
|
||||||
var err error
|
err := run(s, kcfg)
|
||||||
|
if err != nil {
|
||||||
|
glog.Errorf("Failed running kubelet: %v", err)
|
||||||
|
}
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
func run(s *options.KubeletServer, kcfg *KubeletConfig) (err error) {
|
||||||
if s.LockFilePath != "" {
|
if s.LockFilePath != "" {
|
||||||
glog.Infof("aquiring lock on %q", s.LockFilePath)
|
glog.Infof("aquiring lock on %q", s.LockFilePath)
|
||||||
if err := flock.Acquire(s.LockFilePath); err != nil {
|
if err := flock.Acquire(s.LockFilePath); err != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user