Exec invokes `kubectl exec` and transfers control to it. This function does not return on success.
()
| 162 | // Exec invokes `kubectl exec` and transfers control to it. |
| 163 | // This function does not return on success. |
| 164 | func (psql *Command) Exec() error { |
| 165 | kubectlExec, err := psql.getKubectlInvocation() |
| 166 | if err != nil { |
| 167 | return err |
| 168 | } |
| 169 | |
| 170 | err = execKubectl(psql.kubectlPath, kubectlExec) |
| 171 | if err != nil { |
| 172 | return err |
| 173 | } |
| 174 | |
| 175 | return nil |
| 176 | } |
| 177 | |
| 178 | // Run starts a psql process inside the target pod |
| 179 | func (psql *Command) Run() error { |
no test coverage detected