From b03831c0b05ce3c376ebd150cf436dca2d80f090 Mon Sep 17 00:00:00 2001 From: "Matthew X. Economou" Date: Tue, 14 Jul 2015 03:22:28 -0400 Subject: [PATCH 1/2] Add support for GitPython and salt-ssh on FreeBSD masters This change tweaks the GitPython package installation state to support alternate package names (on FreeBSD, it's called "py27-GitPython"). Also, on FreeBSD salt-ssh is included in the "py27-salt" package by default, requiring an update to `distro_map`. --- salt/defaults.yaml | 1 + salt/gitfs/gitpython.sls | 3 ++- salt/map.jinja | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/salt/defaults.yaml b/salt/defaults.yaml index 4b4562c..511e7ec 100644 --- a/salt/defaults.yaml +++ b/salt/defaults.yaml @@ -18,6 +18,7 @@ salt: salt_api: salt-api salt_ssh: salt-ssh + python_git: python-git python_cherrypy: python-cherrypy python_tornado: python-tornado diff --git a/salt/gitfs/gitpython.sls b/salt/gitfs/gitpython.sls index 7fa09ef..5d90be8 100644 --- a/salt/gitfs/gitpython.sls +++ b/salt/gitfs/gitpython.sls @@ -8,6 +8,7 @@ GitPython: {% else %} python-git: - pkg.installed + pkg.installed: + - name: {{ salt_settings['python_git'] }} {% endif %} diff --git a/salt/map.jinja b/salt/map.jinja index 9878a77..3643c18 100644 --- a/salt/map.jinja +++ b/salt/map.jinja @@ -48,6 +48,8 @@ that differ from whats in defaults.yaml 'salt_syndic': 'py27-salt', 'salt_cloud': 'py27-salt', 'salt_api': 'py27-salt', + 'salt_ssh': 'py27-salt', + 'python_git': 'py27-GitPython', 'config_path': '/usr/local/etc/salt', 'minion_service': 'salt_minion', 'master_service': 'salt_master', From 14b466e02216a1d08ae31c3b86b9019e1ea0360b Mon Sep 17 00:00:00 2001 From: "Matthew X. Economou" Date: Tue, 14 Jul 2015 09:40:16 -0400 Subject: [PATCH 2/2] Change variable lookup to match usage in other states Done at the maintainer's request. --- salt/gitfs/gitpython.sls | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/salt/gitfs/gitpython.sls b/salt/gitfs/gitpython.sls index 5d90be8..f1a48e6 100644 --- a/salt/gitfs/gitpython.sls +++ b/salt/gitfs/gitpython.sls @@ -9,6 +9,6 @@ GitPython: python-git: pkg.installed: - - name: {{ salt_settings['python_git'] }} + - name: {{ salt_settings.python_git }} {% endif %}