Add fmt.printf for other need

Signed-off-by: 's avatarhuzhifeng <huzhifeng@douyu.tv>
parent 3196300f
...@@ -17,6 +17,7 @@ limitations under the License. ...@@ -17,6 +17,7 @@ limitations under the License.
package main package main
import ( import (
"fmt"
"os" "os"
"k8s.io/kubernetes/cmd/kubeadm/app" "k8s.io/kubernetes/cmd/kubeadm/app"
...@@ -24,6 +25,7 @@ import ( ...@@ -24,6 +25,7 @@ import (
func main() { func main() {
if err := app.Run(); err != nil { if err := app.Run(); err != nil {
fmt.Fprintf(os.Stderr, "error: %v\n", err)
os.Exit(1) os.Exit(1)
} }
os.Exit(0) os.Exit(0)
......
...@@ -17,6 +17,7 @@ limitations under the License. ...@@ -17,6 +17,7 @@ limitations under the License.
package main package main
import ( import (
"fmt"
"os" "os"
"k8s.io/kubernetes/cmd/kubectl/app" "k8s.io/kubernetes/cmd/kubectl/app"
...@@ -24,6 +25,7 @@ import ( ...@@ -24,6 +25,7 @@ import (
func main() { func main() {
if err := app.Run(); err != nil { if err := app.Run(); err != nil {
fmt.Fprintf(os.Stderr, "error: %v\n", err)
os.Exit(1) os.Exit(1)
} }
os.Exit(0) os.Exit(0)
......
...@@ -106,6 +106,7 @@ func main() { ...@@ -106,6 +106,7 @@ func main() {
// run the kubelet // run the kubelet
if err := app.Run(kubeletServer, kubeletDeps); err != nil { if err := app.Run(kubeletServer, kubeletDeps); err != nil {
fmt.Fprintf(os.Stderr, "error: %v\n", err)
die(err) die(err)
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment