diff --git a/salt/hg/files/hg/wsgi/python.wsgi b/salt/hg/files/hg/wsgi/python.wsgi index 5632caaf..058bbaa1 100644 --- a/salt/hg/files/hg/wsgi/python.wsgi +++ b/salt/hg/files/hg/wsgi/python.wsgi @@ -3,4 +3,9 @@ from mercurial import encoding CONFIG = '/srv/hg/repos.conf' encoding.encoding = 'utf-8' +{% if grains["oscodename"] == "noble" %} application = hgwebdir(CONFIG.encode()) +{% else %} +application = hgwebdir(CONFIG) +{% endif %} + diff --git a/salt/hg/init.sls b/salt/hg/init.sls index 22f739b7..369c7542 100644 --- a/salt/hg/init.sls +++ b/salt/hg/init.sls @@ -2,7 +2,9 @@ hg-deps: pkg.installed: - pkgs: - mercurial + {% if grains["oscodename"] == ["noble"] %} - python3-pygments + {% endif %} svn-deps: pkg.installed: @@ -159,7 +161,7 @@ apache2: pkg.installed: - pkgs: - apache2 - - libapache2-mod-wsgi-py3 + - libapache2-mod-wsgi{% if grains["oscodename"] == ["noble"] %}-py3{% endif %} service.running: - enable: True - reload: True