Skip to content

Commit

Permalink
Merge pull request #12 from IvanKuchin/development
Browse files Browse the repository at this point in the history
infrastructure: dedicated folder for secret
  • Loading branch information
IvanKuchin authored Jun 8, 2021
2 parents fe3d0ad + 96d7c6e commit d8c7119
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ set(GIT_INSTALL_DIR ${LOCAL_INSTALL_DIR}/git)
set(PDF_FONT_INSTALL_DIR ${LOCAL_INSTALL_DIR}/libpdf-font)
set(LIBXL_INSTALL_DIR ${LOCAL_INSTALL_DIR}/libxl)
set(CONFIG_INSTALL_DIR ${LOCAL_INSTALL_DIR}/config)
set(SECRET_INSTALL_DIR ${LOCAL_INSTALL_DIR}/secret)
set(SSMTP_INSTALL_DIR ${LOCAL_INSTALL_DIR}/ssmtp)

# ---- libxl library is not in apt-reporsitory, therefore is not installed on the OS
Expand Down
2 changes: 1 addition & 1 deletion src/pd/c_smartway.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ string C_Smartway::GetAuthJSON()
MESSAGE_DEBUG("", "", "start");

vector<string> config_keys = {"SMARTWAY_LOGIN", "SMARTWAY_PASSWORD"};
auto auth_map = config->GetFromFullPathFile(SECRET_DIR, SECRET_FILE, config_keys);
auto auth_map = config->GetFromFile(SECRET_FILE, config_keys);
auto is_auth_valid = (auth_map["SMARTWAY_LOGIN"].length() > 0);
auto __SMARTWAY_LOGIN = (is_auth_valid ? auth_map["SMARTWAY_LOGIN"] : "");
auto __SMARTWAY_PASSWORD = (is_auth_valid ? auth_map["SMARTWAY_PASSWORD"] : "");
Expand Down

0 comments on commit d8c7119

Please sign in to comment.