Merge branch 'tweak/default-creds' into 'dev'

Add info note to default creds file

See merge request crafty-controller/crafty-4!760
This commit is contained in:
Iain Powrie 2024-06-23 14:15:12 +00:00
commit b7830ec00b
2 changed files with 10 additions and 2 deletions

View File

@ -5,7 +5,7 @@ TBD
### Bug fixes
TBD
### Tweaks
TBD
- Add info note to default creds file ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/760))
### Lang
- Add remaining `he_IL`, `th_TH` translations for 4.4.0 Release ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/761))
<br><br>

10
main.py
View File

@ -367,7 +367,15 @@ if __name__ == "__main__":
encoding="utf-8",
) as cred_file:
cred_file.write(
json.dumps({"username": "admin", "password": PASSWORD}, indent=4)
json.dumps(
{
"username": "admin",
"password": PASSWORD,
"info": "This is NOT where you change your password."
" This file is only a means to give you a default password.",
},
indent=4,
)
)
os.chmod(
os.path.join(APPLICATION_PATH, "app", "config", "default-creds.txt"), 0o600