saltstack-formulas / postgres-formula

http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html
Other
77 stars 283 forks source link

fix(repo): reorder dependencies to prevent errors #309

Closed javierbertoli closed 3 years ago

javierbertoli commented 3 years ago

PR progress checklist (to be filled in by reviewers)


What type of PR is this?

Primary type

Secondary type

Does this PR introduce a BREAKING CHANGE?

No.

Related issues and/or pull requests

Describe the changes you're proposing

When installing a postgresql-client using upstream's repo, the formula fails to install the repo because a require_in dependency expects the postgresql-server package. This PR moves the dependency to the server/init.sls state.

Pillar / config required to test the proposed changes

The issue can be reproduced using this pillar

postgres:
  use_upstream_repo: true
  version: 11

and this command

salt-call --local state.apply postgres.client

Debug log showing how the proposed changes work

Documentation checklist

Testing checklist

Additional context

sticky-note commented 3 years ago

This is the exact contrary of this https://github.com/saltstack-formulas/postgres-formula/pull/300 which was introduced because when use_upstream_repo: True on FreeBSD the require: postgresql-repo fails to find the right due probably to this line https://github.com/saltstack-formulas/postgres-formula/blob/7d46b273af8ae46b2e2c9bfec41b417c6eeb24aa/postgres/upstream.sls#L4

Not sure of what I am saying, I had the exact same problem today but this PR need to be double checked

sticky-note commented 3 years ago

Ok, it seems to have no issue in this manner. Thanks @javierbertoli

javierbertoli commented 3 years ago

Thanks to you both!

saltstack-formulas-travis commented 3 years ago

:tada: This PR is included in version 0.41.6 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: