Improve authentication setup documentation and error messages#762
Merged
Improve authentication setup documentation and error messages#762
Conversation
The fail-closed panic when WF_AUTH_PASSWORD_HASH is unset on non-loopback addresses was confusing Docker users — the compose.yml comments said the hash was only "recommended" and didn't mention WF_AUTH_REQUIRED. - compose.yml: clarify that auth is required on 0.0.0.0, document dollar-sign escaping, surface WF_AUTH_REQUIRED option - config.rs: expand panic message with actionable fix steps - auth.rs: improve AuthManager::new error to hint at $ escaping - README.md: add dollar-sign escaping cheat-sheet table https://claude.ai/code/session_01AKRG2muLKf4dFxgjs3qE4M
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR enhances the authentication setup experience by providing clearer documentation and more helpful error messages for users configuring password-based authentication.
Changes
Documentation improvements:
.envfiles, Docker Compose YAML, anddocker runcommandscompose.ymlcomments with detailed authentication setup instructions, including password hash generation command and escaping guidanceWF_AUTH_REQUIREDconfiguration optionError message improvements:
config.rswhen authentication is required but not configured, breaking it into numbered steps with specific instructionsauth.rswhenWF_AUTH_PASSWORD_HASHfails to parse, explaining the expected format and escaping requirements for different contextsMotivation
Users frequently struggle with:
$characters in different configuration contexts (.env, YAML, shell)These changes provide clear, actionable guidance at the point of configuration and failure, reducing setup friction.
Checklist
By submitting this PR, I agree to the CLA.
https://claude.ai/code/session_01AKRG2muLKf4dFxgjs3qE4M