23 #ifndef DOBBYBUNDLECONFIG_H
24 #define DOBBYBUNDLECONFIG_H
26 #include "DobbyConfig.h"
49 const std::shared_ptr<const IDobbySettings>& settings,
51 const std::string& bundlePath);
58 uid_t userId()
const override;
59 gid_t groupId()
const override;
67 bool consoleDisabled()
const override;
68 ssize_t consoleLimit()
const override;
69 const std::string& consolePath()
const override;
72 bool restartOnCrash()
const override;
75 const std::string& rootfsPath()
const override;
78 std::shared_ptr<rt_dobby_schema> config()
const override;
81 const std::map<std::string, Json::Value>& rdkPlugins()
const override;
83 #if defined(LEGACY_COMPONENTS)
85 const std::map<std::string, Json::Value>& legacyPlugins()
const override;
95 const std::string& bundlePath);
98 #if defined(LEGACY_COMPONENTS)
99 bool processLegacyPlugins(
const Json::Value& value);
108 const std::shared_ptr<const IDobbySettings> mSettings;
115 std::shared_ptr<rt_dobby_schema> mConf;
123 bool mRestartOnCrash;
131 bool mConsoleDisabled;
132 std::string mConsolePath;
133 ssize_t mConsoleLimit;
136 std::map<std::string, Json::Value> mRdkPlugins;
138 #if defined(LEGACY_COMPONENTS)
140 std::map<std::string, Json::Value> mLegacyPlugins;
144 std::string mRootfsPath;
A wrapper around a std::string, used to add some type definition to to an id and also to sanity check...
Definition: ContainerId.h:41
Takes a JSON formatted OCI bundle configuration file in the constructor, parses it and extracts the r...
Definition: DobbyBundleConfig.h:42
const std::shared_ptr< IDobbyUtils > mUtilities
Definition: DobbyBundleConfig.h:107
bool constructConfig(const ContainerId &id, const std::string &bundlePath)
Creates config object.
Definition: DobbyBundleConfig.cpp:113
bool parseOCIConfig(const std::string &bundlePath)
Parses the bundle config's contents that are needed by plugins.
Definition: DobbyBundleConfig.cpp:233
DobbyBundleConfig(const std::shared_ptr< IDobbyUtils > &utils, const std::shared_ptr< const IDobbySettings > &settings, const ContainerId &id, const std::string &bundlePath)
Constructor that parses an OCI bundle's config file to be used by Dobby. Plugins under 'rdkPlugins' a...
Definition: DobbyBundleConfig.cpp:47
bool isValid() const override
Getters used for plugins.
Definition: DobbyBundleConfig.cpp:150
Interface that configuration file parser classes have to implement.
Definition: DobbyConfig.h:66
BusType
The type of dbus to call methods on / emit signals.
Definition: IDobbyIPCUtils.h:60