saltstack-formulas / nginx-formula

Nginx Salt Formula
http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html
Other
163 stars 421 forks source link

Make openSUSE devel repository optional #299

Closed tacerus closed 1 year ago

tacerus commented 1 year ago

PR progress checklist (to be filled in by reviewers)


What type of PR is this?

local:
----------
          ID: nginx_zypp_repo
    Function: pkgrepo.absent
        Name: server_http
      Result: False
     Comment: An exception occurred in this state: Traceback (most recent call last):
                File "/usr/lib/python3.6/site-packages/salt/state.py", line 2215, in call
                  *cdata["args"], **cdata["kwargs"]
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 1203, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                File "/usr/lib/python3.6/site-packages/contextvars/__init__.py", line 38, in run
                  return callable(*args, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 1218, in _run_as
                  return _func_or_method(*args, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 1251, in wrapper
                  return f(*args, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/states/pkgrepo.py", line 648, in absent
                  __salt__["pkg.del_repo"](repo=name, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 1203, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                File "/usr/lib/python3.6/site-packages/contextvars/__init__.py", line 38, in run
                  return callable(*args, **kwargs)
                File "/usr/lib/python3.6/site-packages/salt/loader/lazy.py", line 1218, in _run_as
                  return _func_or_method(*args, **kwargs)
              TypeError: del_repo() got an unexpected keyword argument 'humanname'
     Started: 03:18:38.809548
    Duration: 22.416 ms
     Changes:   

Primary type

Apologies, two types in one PR - if you prefer, I can split the bugfix out, but I figured it goes hand in hand.

Secondary type

Does this PR introduce a BREAKING CHANGE?

Yes.

Users currently using the openSUSE devel repository should decide whether they want to continue using it, requiring them to set install_from_opensuse_devel: true, or whether they are fine with switching to the package in the official repository in modern releases of openSUSE (OSS/SLE Update repository on Leap 15.4).

Users on SUSE Linux Enterprise should be encouraged to enable the Web Applications module, which provides an official SUSE build of nginx.

Related issues and/or pull requests

n/a

Describe the changes you're proposing

Pillar / config required to test the proposed changes

nginx:
  install_from_opensuse_devel: true

Debug log showing how the proposed changes work

GitHub prevents me from pasting the logs, complaining "Pull request creation failed. Validation failed: Body is too long (maximum is 65536 characters)" and deleting all my existing body content - even if I wrap the snippets in <details>.

You can find the output for three months here: https://paste.opensuse.org/pastes/dea95f9e3be7 (true) https://paste.opensuse.org/pastes/5a351448cbf1 (false)

Documentation checklist

Testing checklist

Additional context

I would appreciate advice on how we can make this change painless for users currently using the devel repository. Should we add a note to the README or add a designated message to the changelog for the next release?

tacerus commented 1 year ago

I'm not sure about the pipelines, there is output like nothing provides rubygem(rack) needed by passenger-6.0.17-1.el8.x86_64, but I don't think my changes caused this, as I did not touch any Passenger related bits. Any ideas?

sticky-note commented 1 year ago

LGTM, thanks for your contribution @tacerus