Merge pull request #49 from andyxning/add_support_for_running_standalone

add support for running standalone
This commit is contained in:
Lantao Liu
2017-01-09 23:35:15 -08:00
committed by GitHub
28 changed files with 3868 additions and 11 deletions
+27 -3
View File
@@ -1,8 +1,12 @@
# node-problem-detector
node-problem-detector aims to make various node problems visible to the upstream
layers in cluster management stack. It is a [DaemonSet](http://kubernetes.io/docs/admin/daemons/)
detecting node problems and reporting them to apiserver. Now it is running as
a [Kubernetes Addon](https://github.com/kubernetes/kubernetes/tree/master/cluster/addons)
layers in cluster management stack.
It is a daemon runs on each node, detects node
problems and reports them to apiserver.
node-problem-detector can either run as a
[DaemonSet](http://kubernetes.io/docs/admin/daemons/) or run standalone.
Now it is running as a
[Kubernetes Addon](https://github.com/kubernetes/kubernetes/tree/master/cluster/addons)
enabled by default in the GCE cluster.
# Background
@@ -48,6 +52,15 @@ List of supported problem daemons:
| [KernelMonitor](https://github.com/kubernetes/node-problem-detector/tree/master/pkg/kernelmonitor) | KernelDeadlock | A problem daemon monitors kernel log and reports problem according to predefined rules. |
# Usage
## Flags
* `-apiserver-override`: An URI parameter used to customize how node-problem-detector
connects the apiserver. The format is the same with the
[`source`](https://github.com/kubernetes/heapster/blob/master/docs/source-configuration.md#kubernetes)
flag of [Heapster](https://github.com/kubernetes/heapster):
```
http://APISERVER_IP:APISERVER_PORT?inClusterConfig=false&userServiceAccount=false&auth=&insecure=
```
## Build Image
Run `make` in the top directory. It will:
* Build the binary.
@@ -92,6 +105,17 @@ spec:
* If needed, you can use [ConfigMap](http://kubernetes.io/docs/user-guide/configmap/)
to overwrite the `config/`.
## Start Standalone
To run node-problem-detector standalone, you should set `inClusterConfig` to `false` and
teach node-problem-detector how to access apiserver with `apiserver-override`.
To run node-problem-detector standalone with an insecure apiserver connection:
```
node-problem-detector -apiserver-override=http://APISERVER_IP:APISERVER_INSECURE_PORT?inClusterConfig=false
```
For more scenarios, see [here](https://github.com/kubernetes/heapster/blob/master/docs/source-configuration.md#kubernetes)
# Links
* [Design Doc](https://docs.google.com/document/d/1cs1kqLziG-Ww145yN6vvlKguPbQQ0psrSBnEqpy0pzE/edit?usp=sharing)
* [Slides](https://docs.google.com/presentation/d/1bkJibjwWXy8YnB5fna6p-Ltiy-N5p01zUsA22wCNkXA/edit?usp=sharing)