From b21a5b7ff470612e2bde5f120aecfbc1a0881689 Mon Sep 17 00:00:00 2001 From: Jhon Honce Date: Thu, 16 Apr 2020 12:06:36 -0700 Subject: Provide a json variable pointing to a configured json API * All commands now using the same instance of json API * `json` variable created in each package to prevent `encoding/json` from being re-introduced Signed-off-by: Jhon Honce --- cmd/podman/common/default.go | 6 ++++++ cmd/podman/common/specgen.go | 1 - 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'cmd/podman/common') diff --git a/cmd/podman/common/default.go b/cmd/podman/common/default.go index 89316270b..7233b2091 100644 --- a/cmd/podman/common/default.go +++ b/cmd/podman/common/default.go @@ -1,5 +1,9 @@ package common +import ( + "github.com/containers/libpod/cmd/podman/registry" +) + var ( // DefaultHealthCheckInterval default value DefaultHealthCheckInterval = "30s" @@ -11,4 +15,6 @@ var ( DefaultHealthCheckTimeout = "30s" // DefaultImageVolume default value DefaultImageVolume = "bind" + // Pull in configured json library + json = registry.JsonLibrary() ) diff --git a/cmd/podman/common/specgen.go b/cmd/podman/common/specgen.go index 4e2ce1e34..43325ef8c 100644 --- a/cmd/podman/common/specgen.go +++ b/cmd/podman/common/specgen.go @@ -1,7 +1,6 @@ package common import ( - "encoding/json" "fmt" "os" "path/filepath" -- cgit v1.2.3-54-g00ecf