.TH "OPENSHIFT CLI SET" "1" " Openshift CLI User Manuals" "Openshift" "June 2016"  ""


.SH NAME
.PP
openshift cli set probe \- Update a probe on a pod template


.SH SYNOPSIS
.PP
\fBopenshift cli set probe\fP [OPTIONS]


.SH DESCRIPTION
.PP
Set or remove a liveness or readiness probe from a pod or pod template

.PP
Each container in a pod may define one or more probes that are used for general health checking. A liveness probe is checked periodically to ensure the container is still healthy: if the probe fails, the container is restarted. Readiness probes set or clear the ready flag for each container, which controls whether the container's ports are included in the list of endpoints for a service and whether a deployment can proceed. A readiness check should indicate when your container is ready to accept incoming traffic or begin handling work. Setting both liveness and readiness probes for each container is highly recommended.

.PP
The three probe types are:
.IP \(bu 2

.IP
\(bu Open a TCP socket on the pod IP
.br
.IP
\(bu Perform an HTTP GET against a URL on a container that must return 200 OK
.br
.IP
\(bu Run a command in the container that must return exit code 0
.br
.PP
Containers that take a variable amount of time to start should set generous initial\-delay\-seconds values, otherwise as your application evolves you may suddenly begin to fail.


.SH OPTIONS
.PP
\fB\-\-all\fP=false
    If true, select all resources in the namespace of the specified resource types

.PP
\fB\-c\fP, \fB\-\-containers\fP="*"
    The names of containers in the selected pod templates to change \- may use wildcards

.PP
\fB\-\-failure\-threshold\fP=0
    The number of failures before the probe is considered to have failed

.PP
\fB\-f\fP, \fB\-\-filename\fP=[]
    Filename, directory, or URL to file to use to edit the resource.

.PP
\fB\-\-get\-url\fP=""
    A URL to perform an HTTP GET on (you can omit the host, have a string port, or omit the scheme.

.PP
\fB\-\-initial\-delay\-seconds\fP=0
    The time in seconds to wait before the probe begins checking

.PP
\fB\-\-liveness\fP=false
    Set or remove a liveness probe to verify this container is running

.PP
\fB\-\-no\-headers\fP=false
    When using the default or custom\-column output format, don't print headers.

.PP
\fB\-\-open\-tcp\fP=""
    A port number or port name to attempt to open via TCP.

.PP
\fB\-o\fP, \fB\-\-output\fP=""
    Output format. One of: json|yaml|wide|name|custom\-columns=...|custom\-columns\-file=...|go\-template=...|go\-template\-file=...|jsonpath=...|jsonpath\-file=... See custom columns [
\[la]http://kubernetes.io/docs/user-guide/kubectl-overview/#custom-columns\[ra]], golang template [
\[la]http://golang.org/pkg/text/template/#pkg-overview\[ra]] and jsonpath template [
\[la]http://kubernetes.io/docs/user-guide/jsonpath\[ra]].

.PP
\fB\-\-output\-version\fP=""
    Output the formatted object with the given group version (for ex: 'extensions/v1beta1').

.PP
\fB\-\-period\-seconds\fP=0
    The time in seconds between attempts

.PP
\fB\-\-readiness\fP=false
    Set or remove a readiness probe to indicate when this container should receive traffic

.PP
\fB\-\-remove\fP=false
    If true, remove the specified probe(s).

.PP
\fB\-l\fP, \fB\-\-selector\fP=""
    Selector (label query) to filter on

.PP
\fB\-a\fP, \fB\-\-show\-all\fP=true
    When printing, show all resources (false means hide terminated pods.)

.PP
\fB\-\-show\-labels\fP=false
    When printing, show all labels as the last column (default hide labels column)

.PP
\fB\-\-sort\-by\fP=""
    If non\-empty, sort list types using this field specification.  The field specification is expressed as a JSONPath expression (e.g. '{.metadata.name}'). The field in the API resource specified by this JSONPath expression must be an integer or a string.

.PP
\fB\-\-success\-threshold\fP=0
    The number of successes required before the probe is considered successful

.PP
\fB\-\-template\fP=""
    Template string or path to template file to use when \-o=go\-template, \-o=go\-template\-file. The template format is golang templates [
\[la]http://golang.org/pkg/text/template/#pkg-overview\[ra]].

.PP
\fB\-\-timeout\-seconds\fP=0
    The time in seconds to wait before considering the probe to have failed


.SH OPTIONS INHERITED FROM PARENT COMMANDS
.PP
\fB\-\-api\-version\fP=""
    DEPRECATED: The API version to use when talking to the server

.PP
\fB\-\-as\fP=""
    Username to impersonate for the operation

.PP
\fB\-\-certificate\-authority\fP=""
    Path to a cert. file for the certificate authority

.PP
\fB\-\-client\-certificate\fP=""
    Path to a client certificate file for TLS

.PP
\fB\-\-client\-key\fP=""
    Path to a client key file for TLS

.PP
\fB\-\-cluster\fP=""
    The name of the kubeconfig cluster to use

.PP
\fB\-\-config\fP=""
    Path to the config file to use for CLI requests.

.PP
\fB\-\-context\fP=""
    The name of the kubeconfig context to use

.PP
\fB\-\-google\-json\-key\fP=""
    The Google Cloud Platform Service Account JSON Key to use for authentication.

.PP
\fB\-\-insecure\-skip\-tls\-verify\fP=false
    If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure

.PP
\fB\-\-log\-flush\-frequency\fP=0
    Maximum number of seconds between log flushes

.PP
\fB\-\-match\-server\-version\fP=false
    Require server version to match client version

.PP
\fB\-n\fP, \fB\-\-namespace\fP=""
    If present, the namespace scope for this CLI request

.PP
\fB\-\-request\-timeout\fP="0"
    The length of time to wait before giving up on a single server request. Non\-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests.

.PP
\fB\-\-server\fP=""
    The address and port of the Kubernetes API server

.PP
\fB\-\-token\fP=""
    Bearer token for authentication to the API server

.PP
\fB\-\-user\fP=""
    The name of the kubeconfig user to use


.SH EXAMPLE
.PP
.RS

.nf
  # Clear both readiness and liveness probes off all containers
  openshift cli set probe dc/registry \-\-remove \-\-readiness \-\-liveness
  
  # Set an exec action as a liveness probe to run 'echo ok'
  openshift cli set probe dc/registry \-\-liveness \-\- echo ok
  
  # Set a readiness probe to try to open a TCP socket on 3306
  openshift cli set probe rc/mysql \-\-readiness \-\-open\-tcp=3306
  
  # Set an HTTP readiness probe for port 8080 and path /healthz over HTTP on the pod IP
  openshift cli set probe dc/webapp \-\-readiness \-\-get\-url=http://:8080/healthz
  
  # Set an HTTP readiness probe over HTTPS on 127.0.0.1 for a hostNetwork pod
  openshift cli set probe dc/router \-\-readiness \-\-get\-url=https://127.0.0.1:1936/stats
  
  # Set only the initial\-delay\-seconds field on all deployments
  openshift cli set probe dc \-\-all \-\-readiness \-\-initial\-delay\-seconds=30

.fi
.RE


.SH SEE ALSO
.PP
\fBopenshift\-cli\-set(1)\fP,


.SH HISTORY
.PP
June 2016, Ported from the Kubernetes man\-doc generator