mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-07-03 18:47:03 +00:00
virtcontainers: fix the issue of missing starting builtin proxy
It shouldn't set kataAgent.state.URL in its configure() method for builtin kata proxy, otherwise the following check of whether is it nil in startProxy() will return directly and failed to start builtin proxy which will log the qemu's console. Fixes: #756 Signed-off-by: fupan <lifupan@gmail.com>
This commit is contained in:
parent
35d3c0bf5a
commit
561269480c
@ -247,7 +247,6 @@ func (k *kataAgent) configure(h hypervisor, id, sharePath string, builtin bool,
|
||||
|
||||
if builtin {
|
||||
k.proxyBuiltIn = true
|
||||
k.state.URL, _ = k.agentURL()
|
||||
}
|
||||
|
||||
// Adding the shared volume.
|
||||
|
@ -649,6 +649,7 @@ func TestAgentConfigure(t *testing.T) {
|
||||
|
||||
err = k.configure(h, id, dir, true, c)
|
||||
assert.Nil(err)
|
||||
assert.Empty(k.state.URL)
|
||||
|
||||
err = k.configure(h, id, dir, false, c)
|
||||
assert.Nil(err)
|
||||
|
Loading…
Reference in New Issue
Block a user