Skip to content

Fix dev package os dependencies #221

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

Merged
merged 1 commit into from
Jun 18, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions postgres/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ postgres:
pkgs_extra: []
pkg_client: postgresql-client
pkg_dev: postgresql-devel
pkg_dev_deps: []
pkg_libpq_dev: libpq-dev
pkg_libs: postgresql-libs
pkg_python: python-psycopg2
Expand Down
18 changes: 5 additions & 13 deletions postgres/dev.sls
Original file line number Diff line number Diff line change
@@ -1,26 +1,18 @@
{% from tpldir + "/map.jinja" import postgres with context %}

{% if grains.os not in ('Windows', 'MacOS',) %}
{%- set pkgs = [postgres.pkg_dev, postgres.pkg_libpq_dev] + postgres.pkg_dev_deps %}

{% if postgres.pkg_dev %}
install-postgres-dev-package:
{% if pkgs %}
install-postgres-dev-packages:
pkg.installed:
- name: {{ postgres.pkg_dev }}
- pkgs: {{ pkgs }}
{% if postgres.fromrepo %}
- fromrepo: {{ postgres.fromrepo }}
{% endif %}
{% endif %}

{% if postgres.pkg_libpq_dev %}
install-postgres-libpq-dev:
pkg.installed:
- name: {{ postgres.pkg_libpq_dev }}
{% if postgres.fromrepo %}
- fromrepo: {{ postgres.fromrepo }}
{% endif %}
{% endif %}

# Alternatives system. Make devclient binaries available in $PATH
# Alternatives system. Make devclient binaries available in $PATH
{%- if 'bin_dir' in postgres and postgres.linux.altpriority %}
{%- for bin in postgres.dev_bins %}
{%- set path = salt['file.join'](postgres.bin_dir, bin) %}
Expand Down
5 changes: 5 additions & 0 deletions postgres/osfamilymap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,11 @@ RedHat:

{% endif %}
pkg_libpq_dev: libpqxx-devel
pkg_dev_deps:
- perl-Time-HiRes
- libicu-devel
- perl-IPC-Run
- perl-Test-Simple

Suse:
pkg_repo:
Expand Down