From 5d748d0c7049c0041a3fc3bb2b15b62de6981295 Mon Sep 17 00:00:00 2001 From: System Administrator Date: Tue, 30 Jun 2015 22:47:29 +0200 Subject: [PATCH] Add gem source server option --- salt/modules/gem.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/salt/modules/gem.py b/salt/modules/gem.py index a2d4030ef9..2b9365ed17 100644 --- a/salt/modules/gem.py +++ b/salt/modules/gem.py @@ -54,7 +54,8 @@ def install(gems, # pylint: disable=C0103 rdoc=False, ri=False, pre_releases=False, - proxy=None): # pylint: disable=C0103 + proxy=None, + source=None): # pylint: disable=C0103 ''' Installs one or several gems. @@ -79,6 +80,9 @@ def install(gems, # pylint: disable=C0103 proxy : None Use the specified HTTP proxy server for all outgoing traffic. Format: http://hostname[:port] + source : None + Use the specified HTTP gem source server to download gem. + Format: http://hostname[:port] CLI Example: @@ -99,6 +103,8 @@ def install(gems, # pylint: disable=C0103 options.append('--pre') if proxy: options.append('-p {0}'.format(proxy)) + if source: + options.append('--source {0}'.format(source)) cmdline_args = ' '.join(options) return _gem('install {gems} {options}'.format(gems=gems,