fix(totp): add totp config in env file (github: #135)

This commit is contained in:
cubic
2023-02-07 11:04:02 +08:00
parent 27dfbfbaaf
commit 6204c834fa
4 changed files with 9 additions and 3 deletions

View File

@@ -114,7 +114,7 @@ define('MAX_DISPLAY_FILE_SIZE', 0x200000); // 2M
define('WORKSPACE_DIR', '/tmp/workspace');
// salt for totp generator
define('TOTP_SALT', 'codefever-salt');
define('TOTP_SALT', YAML_TOTP_SALT);
// default paging sessing
define('DEFAULT_PAGE_SIZE', 20);

View File

@@ -21,6 +21,10 @@ session:
name: codefever_community
key: <session_key>
# totp settings (for verification code generating)
totp:
salt: <totp_salt_for_codefever>
# path
path:
file: file-storage

View File

@@ -84,5 +84,6 @@ echo '=== IMPORTANT NOTICE ==='
echo '1. You shuold edit file </data/www/codefever-community/env.yaml: mysql/*> to finish mysql settings.'
echo '2. You shuold edit file </data/www/codefever-community/env.yaml: session/*> to finish cookie settings.'
echo '3. You shuold edit file </data/www/codefever-community/env.yaml: gateway/token> to finish git gateway security settings.'
echo '4. Run sh ./create_db.sh after change env.yaml.'
echo '5. Run sh ./remove_test_data.sh if you DO NOT need to run unit test.'
echo '4. You shuold edit file </data/www/codefever-community/env.yaml: totp/salt> to finish verification code security settings.'
echo '5. Run sh ./create_db.sh after change env.yaml.'
echo '6. Run sh ./remove_test_data.sh if you DO NOT need to run unit test.'

View File

@@ -77,4 +77,5 @@ echo -e "\n\n\n"
echo '=== IMPORTANT NOTICE ==='
echo '1. CodeFever Comminuty Upgrated.'
echo '2. Check <./env.yaml> file, copy <totp/salt> section from <./env.template.yaml> if not exsit.'
echo 'have fun!'