From 6b543be50bcbc35ef0fc697c913e6e3f2d7999d1 Mon Sep 17 00:00:00 2001 From: Mrunal Patel Date: Tue, 11 Jul 2017 16:19:18 -0700 Subject: [PATCH] Rename remnants of ocid to crio Signed-off-by: Mrunal Patel --- server/config.go | 22 +++++++++++----------- server/server.go | 4 ++-- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/server/config.go b/server/config.go index 081dacdd..c15e62e7 100644 --- a/server/config.go +++ b/server/config.go @@ -172,7 +172,7 @@ type NetworkConfig struct { // TOML-friendly (it has all of the explicit tables). It's just used for // conversions. type tomlConfig struct { - Ocid struct { + Crio struct { RootConfig API struct{ APIConfig } `toml:"api"` Runtime struct{ RuntimeConfig } `toml:"runtime"` @@ -182,19 +182,19 @@ type tomlConfig struct { } func (t *tomlConfig) toConfig(c *Config) { - c.RootConfig = t.Ocid.RootConfig - c.APIConfig = t.Ocid.API.APIConfig - c.RuntimeConfig = t.Ocid.Runtime.RuntimeConfig - c.ImageConfig = t.Ocid.Image.ImageConfig - c.NetworkConfig = t.Ocid.Network.NetworkConfig + c.RootConfig = t.Crio.RootConfig + c.APIConfig = t.Crio.API.APIConfig + c.RuntimeConfig = t.Crio.Runtime.RuntimeConfig + c.ImageConfig = t.Crio.Image.ImageConfig + c.NetworkConfig = t.Crio.Network.NetworkConfig } func (t *tomlConfig) fromConfig(c *Config) { - t.Ocid.RootConfig = c.RootConfig - t.Ocid.API.APIConfig = c.APIConfig - t.Ocid.Runtime.RuntimeConfig = c.RuntimeConfig - t.Ocid.Image.ImageConfig = c.ImageConfig - t.Ocid.Network.NetworkConfig = c.NetworkConfig + t.Crio.RootConfig = c.RootConfig + t.Crio.API.APIConfig = c.APIConfig + t.Crio.Runtime.RuntimeConfig = c.RuntimeConfig + t.Crio.Image.ImageConfig = c.ImageConfig + t.Crio.Network.NetworkConfig = c.NetworkConfig } // FromFile populates the Config from the TOML-encoded file at the given path. diff --git a/server/server.go b/server/server.go index 17ca8364..fd6a5ae5 100644 --- a/server/server.go +++ b/server/server.go @@ -536,10 +536,10 @@ func (s *Server) cleanupSandboxesOnShutdown() { // Shutdown attempts to shut down the server's storage cleanly func (s *Server) Shutdown() error { - // why do this on clean shutdown! we want containers left running when ocid + // why do this on clean shutdown! we want containers left running when crio // is down for whatever reason no?! // notice this won't trigger just on system halt but also on normal - // ocid.service restart!!! + // crio.service restart!!! s.cleanupSandboxesOnShutdown() _, err := s.store.Shutdown(false) return err