Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support creation of .pgpass file #229

Closed
3 tasks
LongLiveCHIEF opened this issue May 17, 2018 · 0 comments · Fixed by #255
Closed
3 tasks

Support creation of .pgpass file #229

LongLiveCHIEF opened this issue May 17, 2018 · 0 comments · Fixed by #255
Assignees
Labels
enhancement New feature or request

Comments

@LongLiveCHIEF
Copy link
Contributor

for gitlab HA installations, there is a .pgpass file that needs to be created on any application_role or pgbouncer_role nodes. Normally this is generated manually by running gitlab-ctl write-pgpass.... command, which creates a file at the userhome for gitlab-consul user (default's to /home/gitlab-consul.

This means we can use a template to create this file and automate this requirement just by having the file present.

  • create variable for pgpass_location, defaults to /home/gitlab-consul/.pgpass
  • create template for .pgpass.erb
  • create variable for pgbouncer_password and inject it into .pgpass.erb

Optional/possibly required:

  • make host, database, user, and hostuser template variables for the .pgpass.erb template

The pattern for this file is such:

"${host}:*:${database}:${user}:${pgbouncer_password}

example outcome would be (with default values shown):

127.0.0.1:*:pgbouncer:pgbouncer:Password
@LongLiveCHIEF LongLiveCHIEF self-assigned this May 17, 2018
@juniorsysadmin juniorsysadmin added the enhancement New feature or request label May 30, 2018
@LongLiveCHIEF LongLiveCHIEF added this to the Gitlab HA Support milestone Jul 8, 2018
LongLiveCHIEF added a commit to LongLiveCHIEF/puppet-gitlab that referenced this issue Jul 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants