mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-07-02 02:02:24 +00:00
virtcontainers: log type of proxy started
In order to see what proxy was started or not, we should log its type and the URL Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com> Signed-off-by: Julio Montes <julio.montes@intel.com>
This commit is contained in:
parent
4680e58e08
commit
3adc8626e8
@ -1200,6 +1200,7 @@ func (k *kataAgent) connect() error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
k.Logger().WithField("url", k.state.URL).Info("New client")
|
||||||
client, err := kataclient.NewAgentClient(k.state.URL, k.proxyBuiltIn)
|
client, err := kataclient.NewAgentClient(k.state.URL, k.proxyBuiltIn)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
@ -24,6 +24,7 @@ func (p *kataProxy) consoleWatched() bool {
|
|||||||
|
|
||||||
// start is kataProxy start implementation for proxy interface.
|
// start is kataProxy start implementation for proxy interface.
|
||||||
func (p *kataProxy) start(sandbox *Sandbox, params proxyParams) (int, string, error) {
|
func (p *kataProxy) start(sandbox *Sandbox, params proxyParams) (int, string, error) {
|
||||||
|
sandbox.Logger().Info("Starting regular Kata proxy rather than built-in")
|
||||||
if sandbox.agent == nil {
|
if sandbox.agent == nil {
|
||||||
return -1, "", fmt.Errorf("No agent")
|
return -1, "", fmt.Errorf("No agent")
|
||||||
}
|
}
|
||||||
|
@ -24,6 +24,7 @@ type noProxy struct {
|
|||||||
|
|
||||||
// start is noProxy start implementation for proxy interface.
|
// start is noProxy start implementation for proxy interface.
|
||||||
func (p *noProxy) start(sandbox *Sandbox, params proxyParams) (int, string, error) {
|
func (p *noProxy) start(sandbox *Sandbox, params proxyParams) (int, string, error) {
|
||||||
|
sandbox.Logger().Info("No proxy started because of no-proxy implementation")
|
||||||
if params.agentURL == "" {
|
if params.agentURL == "" {
|
||||||
return -1, "", fmt.Errorf("AgentURL cannot be empty")
|
return -1, "", fmt.Errorf("AgentURL cannot be empty")
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user