containerd-stress: use config address for CRI test
This change removes the hard-coded containerd endpoint for CRI test and use the address in the config which would honor the CLI flag. Signed-off-by: Yibo Zhuang <yibzhuang@gmail.com>
This commit is contained in:
parent
787943dc10
commit
c384e37177
@ -267,10 +267,9 @@ func criTest(c config) error {
|
|||||||
timeout = 1 * time.Minute
|
timeout = 1 * time.Minute
|
||||||
wg sync.WaitGroup
|
wg sync.WaitGroup
|
||||||
ctx = namespaces.WithNamespace(context.Background(), stressNs)
|
ctx = namespaces.WithNamespace(context.Background(), stressNs)
|
||||||
criEndpoint = "unix:///run/containerd/containerd.sock"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
client, err := remote.NewRuntimeService(criEndpoint, timeout)
|
client, err := remote.NewRuntimeService(c.Address, timeout)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("failed to create runtime service: %w", err)
|
return fmt.Errorf("failed to create runtime service: %w", err)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user