pub struct PodLogOptions {
pub container: Option<String>,
pub follow: Option<bool>,
pub previous: Option<bool>,
pub since_seconds: Option<i64>,
pub since_time: Option<Time>,
pub timestamps: Option<bool>,
pub tail_lines: Option<i64>,
pub limit_bytes: Option<i64>,
pub insecure_skip_tls_verify_backend: Option<bool>,
pub stream: Option<String>,
}
Expand description
PodLogOptions is the query options for a Pod’s logs REST call.
Fields§
§container: Option<String>
The container for which to stream logs. Defaults to only container if there is one container in the pod. +optional
follow: Option<bool>
Follow the log stream of the pod. Defaults to false. +optional
previous: Option<bool>
Return previous terminated container logs. Defaults to false. +optional
since_seconds: Option<i64>
A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified. +optional
since_time: Option<Time>
An RFC3339 timestamp from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified. +optional
timestamps: Option<bool>
If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false. +optional
tail_lines: Option<i64>
If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when “TailLines” is specified, “Stream” can only be set to nil or “All”. +optional
limit_bytes: Option<i64>
If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit. +optional
insecure_skip_tls_verify_backend: Option<bool>
insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver’s TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet). +optional
stream: Option<String>
Specify which container log stream to return to the client. Acceptable values are “All”, “Stdout” and “Stderr”. If not specified, “All” is used, and both stdout and stderr are returned interleaved. Note that when “TailLines” is specified, “Stream” can only be set to nil or “All”. +featureGate=PodLogsQuerySplitStreams +optional
Implementations§
Source§impl PodLogOptions
impl PodLogOptions
Sourcepub fn container(&self) -> &str
pub fn container(&self) -> &str
Returns the value of container
, or the default value if container
is unset.
Sourcepub fn follow(&self) -> bool
pub fn follow(&self) -> bool
Returns the value of follow
, or the default value if follow
is unset.
Sourcepub fn previous(&self) -> bool
pub fn previous(&self) -> bool
Returns the value of previous
, or the default value if previous
is unset.
Sourcepub fn since_seconds(&self) -> i64
pub fn since_seconds(&self) -> i64
Returns the value of since_seconds
, or the default value if since_seconds
is unset.
Sourcepub fn timestamps(&self) -> bool
pub fn timestamps(&self) -> bool
Returns the value of timestamps
, or the default value if timestamps
is unset.
Sourcepub fn tail_lines(&self) -> i64
pub fn tail_lines(&self) -> i64
Returns the value of tail_lines
, or the default value if tail_lines
is unset.
Sourcepub fn limit_bytes(&self) -> i64
pub fn limit_bytes(&self) -> i64
Returns the value of limit_bytes
, or the default value if limit_bytes
is unset.
Sourcepub fn insecure_skip_tls_verify_backend(&self) -> bool
pub fn insecure_skip_tls_verify_backend(&self) -> bool
Returns the value of insecure_skip_tls_verify_backend
, or the default value if insecure_skip_tls_verify_backend
is unset.
Trait Implementations§
Source§impl Clone for PodLogOptions
impl Clone for PodLogOptions
Source§fn clone(&self) -> PodLogOptions
fn clone(&self) -> PodLogOptions
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for PodLogOptions
impl Debug for PodLogOptions
Source§impl Default for PodLogOptions
impl Default for PodLogOptions
Source§impl Hash for PodLogOptions
impl Hash for PodLogOptions
Source§impl Message for PodLogOptions
impl Message for PodLogOptions
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.