This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
#include "utils/utils.hpp"
|
||||
#include "templates.hpp"
|
||||
#include "config.hpp"
|
||||
#include "utils/hash.hpp"
|
||||
|
||||
namespace dropshell {
|
||||
|
||||
@@ -307,7 +308,6 @@
|
||||
std::vector<std::string> required_files = {
|
||||
"config/service.env",
|
||||
"config/.template_info.env",
|
||||
"_default.env",
|
||||
"install.sh",
|
||||
"uninstall.sh"
|
||||
};
|
||||
@@ -376,8 +376,16 @@
|
||||
mLocationID(location_id),
|
||||
mTemplateLocalPath(local_template_path),
|
||||
mTemplateValid(template_manager::test_template(local_template_path.string())),
|
||||
mIsSet(!template_name.empty() && !location_id.empty() && !local_template_path.empty())
|
||||
mIsSet(!template_name.empty() && !location_id.empty() && !local_template_path.empty()),\
|
||||
mHash(0)
|
||||
{
|
||||
if (!std::filesystem::exists(local_template_path))
|
||||
{
|
||||
error << "Template path does not exist: " << local_template_path << std::endl;
|
||||
return;
|
||||
}
|
||||
|
||||
mHash = hash_directory_recursive(local_template_path);
|
||||
}
|
||||
|
||||
} // namespace dropshell
|
||||
|
Reference in New Issue
Block a user