Skip to content
This repository has been archived by the owner on Feb 13, 2023. It is now read-only.
/ drupal-vm Public archive

Commit

Permalink
Issue #2024: Update postgresql role to latest version.
Browse files Browse the repository at this point in the history
geerlingguy committed Mar 20, 2020
1 parent 457f88c commit 9400ee5
Showing 9 changed files with 80 additions and 3 deletions.
2 changes: 1 addition & 1 deletion provisioning/requirements.yml
Original file line number Diff line number Diff line change
@@ -67,7 +67,7 @@ roles:
- name: geerlingguy.postfix
version: 2.0.0
- name: geerlingguy.postgresql
version: 2.1.0
version: 2.2.0
- name: geerlingguy.redis
version: 1.6.0
- name: geerlingguy.repo-remi
56 changes: 56 additions & 0 deletions provisioning/roles/geerlingguy.postgresql/.github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Configuration for probot-stale - https://github.com/probot/stale

# Number of days of inactivity before an Issue or Pull Request becomes stale
daysUntilStale: 90

# Number of days of inactivity before an Issue or Pull Request with the stale label is closed.
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
daysUntilClose: 30

# Only issues or pull requests with all of these labels are check if stale. Defaults to `[]` (disabled)
onlyLabels: []

# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable
exemptLabels:
- pinned
- security
- planned

# Set to true to ignore issues in a project (defaults to false)
exemptProjects: false

# Set to true to ignore issues in a milestone (defaults to false)
exemptMilestones: false

# Set to true to ignore issues with an assignee (defaults to false)
exemptAssignees: false

# Label to use when marking as stale
staleLabel: stale

# Limit the number of actions per hour, from 1-30. Default is 30
limitPerRun: 30

pulls:
markComment: |-
This pull request has been marked 'stale' due to lack of recent activity. If there is no further activity, the PR will be closed in another 30 days. Thank you for your contribution!
Please read [this blog post](https://www.jeffgeerling.com/blog/2020/enabling-stale-issue-bot-on-my-github-repositories) to see the reasons why I mark pull requests as stale.
unmarkComment: >-
This pull request is no longer marked for closure.
closeComment: >-
This pull request has been closed due to inactivity. If you feel this is in error, please reopen the pull request or file a new PR with the relevant details.
issues:
markComment: |-
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read [this blog post](https://www.jeffgeerling.com/blog/2020/enabling-stale-issue-bot-on-my-github-repositories) to see the reasons why I mark issues as stale.
unmarkComment: >-
This issue is no longer marked for closure.
closeComment: >-
This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details.
1 change: 1 addition & 0 deletions provisioning/roles/geerlingguy.postgresql/.travis.yml
Original file line number Diff line number Diff line change
@@ -9,6 +9,7 @@ env:
- MOLECULE_DISTRO: centos7
- MOLECULE_DISTRO: centos8
- MOLECULE_DISTRO: fedora31
- MOLECULE_DISTRO: ubuntu2004
- MOLECULE_DISTRO: ubuntu1804
- MOLECULE_DISTRO: debian10

4 changes: 4 additions & 0 deletions provisioning/roles/geerlingguy.postgresql/README.md
Original file line number Diff line number Diff line change
@@ -106,6 +106,10 @@ A list of databases to ensure exist on the server. Only the `name` is required;

A list of users to ensure exist on the server. Only the `name` is required; all other properties are optional.

postgres_users_no_log: true

Whether to output user data (which may contain sensitive information, like passwords) when managing users.

postgresql_version: [OS-specific]
postgresql_data_dir: [OS-specific]
postgresql_bin_path: [OS-specific]
3 changes: 3 additions & 0 deletions provisioning/roles/geerlingguy.postgresql/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -62,3 +62,6 @@ postgresql_users: []
# login_unix_socket: # defaults to 1st of postgresql_unix_socket_directories
# port: # defaults to not set
# state: # defaults to 'present'

# Whether to output user data when managing users.
postgres_users_no_log: true
3 changes: 2 additions & 1 deletion provisioning/roles/geerlingguy.postgresql/meta/main.yml
Original file line number Diff line number Diff line change
@@ -6,7 +6,7 @@ galaxy_info:
description: PostgreSQL server for Linux.
company: "Midwestern Mac, LLC"
license: "license (BSD, MIT)"
min_ansible_version: 2.4
min_ansible_version: 2.8
platforms:
- name: EL
versions:
@@ -22,6 +22,7 @@ galaxy_info:
versions:
- xenial
- bionic
- focal
- name: Debian
versions:
- wheezy
Original file line number Diff line number Diff line change
@@ -23,6 +23,7 @@

- name: Update apt cache.
apt: update_cache=true cache_valid_time=600
changed_when: false
when: ansible_os_family == 'Debian'

- name: Set custom variables for old CentOS 6 PostgreSQL install.
2 changes: 1 addition & 1 deletion provisioning/roles/geerlingguy.postgresql/tasks/users.yml
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@
port: "{{ item.port | default(omit) }}"
state: "{{ item.state | default('present') }}"
with_items: "{{ postgresql_users }}"
no_log: true
no_log: "{{ postgres_users_no_log }}"
become: true
become_user: "{{ postgresql_user }}"
# See: https://github.com/ansible/ansible/issues/16048#issuecomment-229012509
11 changes: 11 additions & 0 deletions provisioning/roles/geerlingguy.postgresql/vars/Ubuntu-20.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
__postgresql_version: "12"
__postgresql_data_dir: "/var/lib/postgresql/{{ __postgresql_version }}/main"
__postgresql_bin_path: "/usr/lib/postgresql/{{ __postgresql_version }}/bin"
__postgresql_config_path: "/etc/postgresql/{{ __postgresql_version }}/main"
__postgresql_daemon: postgresql
__postgresql_packages:
- postgresql
- postgresql-contrib
- libpq-dev
postgresql_python_library: python3-psycopg2

0 comments on commit 9400ee5

Please sign in to comment.