saltstack-formulas / apache-formula

Set up and configure the Apache HTTP server

Home Page:http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[BUG] apache.config.modules.mod_wsgi fails, pkg: apache not found

iaingeorgeson opened this issue · comments

Your setup

Formula commit hash / release tag

v1.1.8

Versions reports (master & minion)

Salt Version:
Salt: 3003.2

Dependency Versions:
cffi: Not Installed
cherrypy: unknown
dateutil: 2.7.3
docker-py: Not Installed
gitdb: 2.0.5
gitpython: 2.1.11
Jinja2: 2.10
libgit2: Not Installed
M2Crypto: 0.31.0
Mako: Not Installed
msgpack: 0.5.6
msgpack-pure: Not Installed
mysql-python: Not Installed
pycparser: Not Installed
pycrypto: 2.6.1
pycryptodome: 3.6.1
pygit2: Not Installed
Python: 3.7.3 (default, Jan 22 2021, 20:04:44)
python-gnupg: Not Installed
PyYAML: 3.13
PyZMQ: 17.1.2
smmap: 2.0.5
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.1

System Versions:
dist: debian 10 buster
locale: UTF-8
machine: x86_64
release: 4.19.0-17-cloud-amd64
system: Linux
version: Debian GNU/Linux 10 buster

Pillar / config used


Bug details

Describe the bug

Including apache.config.modules.mod_wsgi fails. pkg: apache-config-modules-wsgi-pkg attempts to require pkg: apache, but that state no longer exists. The correct name is now apache-package-install-pkg-installed

https://github.com/saltstack-formulas/apache-formula/blob/v1.1.8/apache/config/modules/mod_wsgi.sls#L17

The mod_ssl.sls state in the same directory uses the correct pkg name.

Steps to reproduce the bug

include:
[...]

  • apache.config.modules.mod_wsgi

Expected behaviour

mod_wsgi is enabled.

Actual behaviour:

      ID: apache-config-modules-wsgi-pkg
Function: pkg.installed
    Name: mod_wsgi
  Result: False
 Comment: The following requisites were not found:
                             require:
                                 pkg: apache

Attempts to fix the bug

Additional context

It looks like the map values used by this sls file are also incorrect in the files used by map.jinja - at least for Ubuntu 20.4. That's apache.pkg.mod_wsgi and apache.conf_mod_wsgi.

Thanks for this report, @iaingeorgeson. Apologies for the delayed response.

This was discussed in one of the recent Formulas working group meetings. The main bug has been fixed in 1002efa. A secondary issue was also resolved by c4dce07.

It looks like the map values used by this sls file are also incorrect in the files used by map.jinja - at least for Ubuntu 20.4. That's apache.pkg.mod_wsgi and apache.conf_mod_wsgi.

Would you mind linking to the specific parts in the YAML files? That will help address this problem.