This pull request introduces functionality allowing users to define default settings for password and passphrase generation using environment variables. This feature aims to enhance automation and standardization across different deployments, particularly benefiting self-hosted environments.
Changes Made
Implemented logic to read environment variables for password and passphrase settings at application startup.
Modified password and passphrase generation routes to use environment-provided defaults when explicit parameters are not specified in the request.
Updated the UI to indicate which settings are being applied, based on the environment variables.
Added validation for environment variable values to ensure they meet expected formats and constraints.
Updated documentation to include details on the new environment variables, their expected values, and usage examples.
Environment Variables Introduced
PW_LENGTH, PW_INCLUDE_UPPERCASE, PW_INCLUDE_DIGITS, PW_INCLUDE_SPECIAL, PW_EXCLUDE_HOMOGLYPHS for passwords.
PP_WORD_COUNT, PP_CAPITALIZE, PP_SEPARATOR_TYPE, PP_USER_DEFINED_SEPARATOR, PP_MAX_WORD_LENGTH, PP_INCLUDE_NUMBERS, PP_INCLUDE_SPECIAL_CHARS, PP_LANGUAGE for passphrases.
Acceptance Criteria
Users can set default settings for password and passphrase generation through environment variables when running the Docker container.
The application reads these environment variables at startup and applies the specified settings as defaults.
Documentation is updated to reflect the introduction of these environment variables and includes examples of their usage.
Potential Challenges & Considerations
Providing clear and comprehensive documentation to aid in the correct usage of these environment variables.
How to Test
Set the environment variables as desired and run the Docker container.
Generate passwords and passphrases without specifying parameters explicitly and verify that the defaults are applied correctly.
Refer to the updated documentation for detailed instructions and examples.
Overview
This pull request introduces functionality allowing users to define default settings for password and passphrase generation using environment variables. This feature aims to enhance automation and standardization across different deployments, particularly benefiting self-hosted environments.
Changes Made
Environment Variables Introduced
PW_LENGTH
,PW_INCLUDE_UPPERCASE
,PW_INCLUDE_DIGITS
,PW_INCLUDE_SPECIAL
,PW_EXCLUDE_HOMOGLYPHS
for passwords.PP_WORD_COUNT
,PP_CAPITALIZE
,PP_SEPARATOR_TYPE
,PP_USER_DEFINED_SEPARATOR
,PP_MAX_WORD_LENGTH
,PP_INCLUDE_NUMBERS
,PP_INCLUDE_SPECIAL_CHARS
,PP_LANGUAGE
for passphrases.Acceptance Criteria
Potential Challenges & Considerations
How to Test
"""