bmc: allow update to use systemd with path

Verification provides a mechanism that has a systemd unit and mode, and
also a path to check the result.  This object can be used for updates,
and will be renamed in a later patchset to be more generically named.

Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I0a995af0aefff76592247775f22fc84189d14903
diff --git a/bmc/buildjson.cpp b/bmc/buildjson.cpp
index 0be61be..8113d9c 100644
--- a/bmc/buildjson.cpp
+++ b/bmc/buildjson.cpp
@@ -118,6 +118,22 @@
                 pack->update = SystemdUpdateMechanism::CreateSystemdUpdate(
                     sdbusplus::bus::new_default(), rebootTarget, rebootMode);
             }
+            else if (updateType == "fileSystemdUpdate")
+            {
+                const auto& path = update.at("path");
+                const auto& unit = update.at("unit");
+
+                /* the mode parameter is optional. */
+                std::string systemdMode = "replace";
+                const auto& mode = update.find("mode");
+                if (mode != update.end())
+                {
+                    systemdMode = update.at("mode").get<std::string>();
+                }
+
+                pack->update = SystemdVerification::CreateVerification(
+                    sdbusplus::bus::new_default(), path, unit, systemdMode);
+            }
             else if (updateType == "systemd")
             {
                 const auto& unit = update.at("unit");