Show a Welcome Page if credentials are created the first time Sunshine is started

This commit is contained in:
Elia Zammuto
2021-07-29 18:55:34 +02:00
parent c243e82047
commit 28fecbc50c
7 changed files with 112 additions and 3 deletions

View File

@@ -94,8 +94,12 @@ int save_user_creds(const std::string &file, const std::string &username, const
BOOST_LOG(info) << "New credentials have been created"sv;
if(run_our_mouth) {
BOOST_LOG(info) << "Username: "sv << username;
BOOST_LOG(info) << "Password: "sv << password;
//BOOST_LOG(info) << "Username: "sv << username;
//BOOST_LOG(info) << "Password: "sv << password;
BOOST_LOG(info) << "Open the Web UI to see your new username and password";
//Save these two in memory to show user and password the first time Sunshine is started
config::sunshine.showCredentials = true;
config::sunshine.plainPassword = password;
}
return 0;