summaryrefslogtreecommitdiff
path: root/pkg/varlinkapi/system.go
diff options
context:
space:
mode:
authorbaude <bbaude@redhat.com>2018-08-04 10:12:27 -0500
committerAtomic Bot <atomic-devel@projectatomic.io>2018-08-05 10:43:32 +0000
commita1e3e542fff562d885354c55f04e0b7f5097a39b (patch)
tree7209d164b97252913bd8533a4326d53629e7566d /pkg/varlinkapi/system.go
parentdebf23c72ae1638a7efb294b6df9497224978d01 (diff)
downloadpodman-a1e3e542fff562d885354c55f04e0b7f5097a39b.tar.gz
podman-a1e3e542fff562d885354c55f04e0b7f5097a39b.tar.bz2
podman-a1e3e542fff562d885354c55f04e0b7f5097a39b.zip
Make one runtime for the varlink service
Rather than making a runtime each time a client hits a varlink endpoint, we now make a single runtime when the varlink service starts up. This fixes a problem where we hit a max inotify limit from CNI. Resolves: #1211 Signed-off-by: baude <bbaude@redhat.com> Closes: #1215 Approved by: rhatdan
Diffstat (limited to 'pkg/varlinkapi/system.go')
-rw-r--r--pkg/varlinkapi/system.go7
1 files changed, 1 insertions, 6 deletions
diff --git a/pkg/varlinkapi/system.go b/pkg/varlinkapi/system.go
index 63acad909..747a25966 100644
--- a/pkg/varlinkapi/system.go
+++ b/pkg/varlinkapi/system.go
@@ -4,7 +4,6 @@ import (
goruntime "runtime"
"strings"
- "github.com/projectatomic/libpod/cmd/podman/libpodruntime"
"github.com/projectatomic/libpod/cmd/podman/varlink"
"github.com/projectatomic/libpod/libpod"
)
@@ -36,11 +35,7 @@ func (i *LibpodAPI) Ping(call ioprojectatomicpodman.VarlinkCall) error {
// GetInfo returns details about the podman host and its stores
func (i *LibpodAPI) GetInfo(call ioprojectatomicpodman.VarlinkCall) error {
podmanInfo := ioprojectatomicpodman.PodmanInfo{}
- runtime, err := libpodruntime.GetRuntime(i.Cli)
- if err != nil {
- return call.ReplyRuntimeError(err.Error())
- }
- info, err := runtime.Info()
+ info, err := i.Runtime.Info()
if err != nil {
return call.ReplyErrorOccurred(err.Error())
}