feat: Automatically disable manage_master_user_password when password is provided
          #565
        
          
      
  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 pull request adds functionality to automatically set
manage_master_user_passwordtofalsewhen the user provides a manualpassword. This ensures that the manually provided password is respected and not overridden by Terraform whenmanage_master_user_passwordis set totrueby default.Motivation and Context
This change resolves an issue where users provide a password, but it is ignored because
manage_master_user_passwordis set totrueby default. By automatically settingmanage_master_user_passwordtofalsewhen a password is provided, the module behaves more intuitively, using the password provided by the user.This change addresses an issue discussed in #510, where the unexpected behavior caused confusion.
Breaking Changes
This change is backward-compatible. If no password is provided, the module will behave as it currently does, with
manage_master_user_passworddefaulting totrue. This ensures that the new behavior only affects users who explicitly provide a password.How Has This Been Tested?
examples/*to demonstrate and validate my change(s)examples/*projectsexamples/complete-postgres. After providing a value topassword,manage_master_user_passwordis automatically set to false.pre-commit run -aon my pull request