Skip to content

Commit

Permalink
Merge pull request #231 from C0rn3j/archinstall
Browse files Browse the repository at this point in the history
Add support for installing packages on Arch Linux
  • Loading branch information
geerlingguy authored Feb 17, 2023
2 parents dda4cbf + 204b672 commit e8db6bb
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,15 @@
- include_tasks: variables.yml

# Setup/install tasks.
- include_tasks: setup-RedHat.yml
when: ansible_os_family == 'RedHat'
- include_tasks: setup-Archlinux.yml
when: ansible_os_family == 'Archlinux'

- include_tasks: setup-Debian.yml
when: ansible_os_family == 'Debian'

- include_tasks: setup-RedHat.yml
when: ansible_os_family == 'RedHat'

- include_tasks: initialize.yml
- include_tasks: configure.yml

Expand Down
21 changes: 21 additions & 0 deletions tasks/setup-Archlinux.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
- name: Ensure PostgreSQL Python libraries are installed.
pacman:
name: "{{ postgresql_python_library }}"
state: present

- name: Ensure PostgreSQL packages are installed.
pacman:
name: "{{ postgresql_packages }}"
state: present

- name: Ensure all configured locales are present.
locale_gen: "name={{ item }} state=present"
with_items: "{{ postgresql_locales }}"
register: locale_gen_result

- name: Force-restart PostgreSQL after new locales are generated.
systemd:
name: "{{ postgresql_daemon }}"
state: restarted
when: locale_gen_result.changed

0 comments on commit e8db6bb

Please sign in to comment.