mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
Fix typo in ExecCommandParam
This commit is contained in:
parent
a3ff0eaf69
commit
786e993338
@ -3852,7 +3852,7 @@ const (
|
|||||||
// Enable TTY for remote command execution
|
// Enable TTY for remote command execution
|
||||||
ExecTTYParam = "tty"
|
ExecTTYParam = "tty"
|
||||||
// Command to run for remote command execution
|
// Command to run for remote command execution
|
||||||
ExecCommandParamm = "command"
|
ExecCommandParam = "command"
|
||||||
|
|
||||||
// Name of header that specifies stream type
|
// Name of header that specifies stream type
|
||||||
StreamType = "streamType"
|
StreamType = "streamType"
|
||||||
|
@ -125,7 +125,7 @@ func fakeServer(t *testing.T, testName string, exec bool, stdinData, stdoutData,
|
|||||||
opts, err := remotecommand.NewOptions(req)
|
opts, err := remotecommand.NewOptions(req)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
if exec {
|
if exec {
|
||||||
cmd := req.URL.Query()[api.ExecCommandParamm]
|
cmd := req.URL.Query()[api.ExecCommandParam]
|
||||||
remotecommand.ServeExec(w, req, executor, "pod", "uid", "container", cmd, opts, 0, 10*time.Second, serverProtocols)
|
remotecommand.ServeExec(w, req, executor, "pod", "uid", "container", cmd, opts, 0, 10*time.Second, serverProtocols)
|
||||||
} else {
|
} else {
|
||||||
remotecommand.ServeAttach(w, req, executor, "pod", "uid", "container", opts, 0, 10*time.Second, serverProtocols)
|
remotecommand.ServeAttach(w, req, executor, "pod", "uid", "container", opts, 0, 10*time.Second, serverProtocols)
|
||||||
|
@ -593,7 +593,7 @@ func getExecRequestParams(req *restful.Request) execRequestParams {
|
|||||||
podName: req.PathParameter("podID"),
|
podName: req.PathParameter("podID"),
|
||||||
podUID: types.UID(req.PathParameter("uid")),
|
podUID: types.UID(req.PathParameter("uid")),
|
||||||
containerName: req.PathParameter("containerName"),
|
containerName: req.PathParameter("containerName"),
|
||||||
cmd: req.Request.URL.Query()[api.ExecCommandParamm],
|
cmd: req.Request.URL.Query()[api.ExecCommandParam],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4606,7 +4606,7 @@ const (
|
|||||||
// Enable TTY for remote command execution
|
// Enable TTY for remote command execution
|
||||||
ExecTTYParam = "tty"
|
ExecTTYParam = "tty"
|
||||||
// Command to run for remote command execution
|
// Command to run for remote command execution
|
||||||
ExecCommandParamm = "command"
|
ExecCommandParam = "command"
|
||||||
|
|
||||||
// Name of header that specifies stream type
|
// Name of header that specifies stream type
|
||||||
StreamType = "streamType"
|
StreamType = "streamType"
|
||||||
|
Loading…
Reference in New Issue
Block a user