Hello community, here is the log from the commit of package salt for openSUSE:Factory checked in at 2013-08-02 15:41:04 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/salt (Old) and /work/SRC/openSUSE:Factory/.salt.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "salt" Changes: -------- --- /work/SRC/openSUSE:Factory/salt/salt.changes 2013-07-30 14:04:39.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.salt.new/salt.changes 2013-08-02 15:41:05.000000000 +0200 @@ -1,0 +2,21 @@ +Fri Aug 2 05:36:08 UTC 2013 - abo...@gmail.com + +- Updated to salt 0.16.2 + - gracefully handle lsb_release data when it is enclosed in quotes + - fixed pillar load from master config + - pillar function pillar.item and pillar.items instead of pillar.data + - fixed traceback when pillar sls is malformed + - gracefully handle quoted publish commands + - publich function publish.item and publish.items instead of publish.data + - salt-key usage in minionswarm script fixed + - minion random reauth_delay added to stagger re-auth attempts. + - improved user and group management + - improved file management + - improved package management + - service management custom initscripts support + - module networking hwaddr renamed to be in line with other modules + - fixed traceback in bridge.show + - fixed ssh know_hosts and auth.present output. + for more information: http://docs.saltstack.com/topics/releases/0.16.2.html + +------------------------------------------------------------------- Old: ---- salt-0.16.1.tar.gz New: ---- salt-0.16.2.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ salt.spec ++++++ --- /var/tmp/diff_new_pack.41vUQi/_old 2013-08-02 15:41:06.000000000 +0200 +++ /var/tmp/diff_new_pack.41vUQi/_new 2013-08-02 15:41:06.000000000 +0200 @@ -17,7 +17,7 @@ Name: salt -Version: 0.16.1 +Version: 0.16.2 Release: 0 Summary: A parallel remote execution system License: Apache-2.0 ++++++ salt-0.16.1.tar.gz -> salt-0.16.2.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/PKG-INFO new/salt-0.16.2/PKG-INFO --- old/salt-0.16.1/PKG-INFO 2013-07-29 19:21:15.000000000 +0200 +++ new/salt-0.16.2/PKG-INFO 2013-08-01 23:42:20.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: salt -Version: 0.16.1 +Version: 0.16.2 Summary: Portable, distributed, remote execution and configuration management system Home-page: http://saltstack.org Author: Thomas S Hatch diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/conf/minion new/salt-0.16.2/conf/minion --- old/salt-0.16.1/conf/minion 2013-07-29 19:01:28.000000000 +0200 +++ new/salt-0.16.2/conf/minion 2013-08-01 23:39:32.000000000 +0200 @@ -103,11 +103,11 @@ # set to zero, the time between reconnection attempts will stay constant. #acceptance_wait_time_max: 0 -# When the master-key changes, the minion will try to re-auth itself to -# receive the new master key. In larger environments this can cause a -# syn-flood on the master because all minions try to re-auth immediately. -# To prevent this and have a minion wait for a random amount of time, -# specify a value here. The wait-time will be chosen in seconds between +# When the master key changes, the minion will try to re-auth itself to receive +# the new master key. In larger environments this can cause a SYN flood on the +# master because all minions try to re-auth immediately. To prevent this and +# have a minion wait for a random amount of time, use this optional parameter. +# The wait-time will be a random number of seconds between # 0 and the defined value. #random_reauth_delay: 60 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/doc/ref/configuration/minion.rst new/salt-0.16.2/doc/ref/configuration/minion.rst --- old/salt-0.16.1/doc/ref/configuration/minion.rst 2013-07-29 19:01:28.000000000 +0200 +++ new/salt-0.16.2/doc/ref/configuration/minion.rst 2013-08-01 23:39:32.000000000 +0200 @@ -69,7 +69,7 @@ .. code-block:: yaml - pidfie: /var/run/salt-minion.pid + pidfile: /var/run/salt-minion.pid .. conf_minion:: root_dir @@ -212,6 +212,22 @@ acceptance_wait_time: 10 +.. conf_minion:: random_reauth_delay + +``random_reauth_delay`` +------------------------ + +When the master key changes, the minion will try to re-auth itself to +receive the new master key. In larger environments this can cause a syn-flood +on the master because all minions try to re-auth immediately. To prevent this +and have a minion wait for a random amount of time, use this optional +parameter. The wait-time will be a random number of seconds between +0 and the defined value. + +.. code-block:: yaml + + random_reauth_delay: 60 + .. conf_minion:: acceptance_wait_time_max ``acceptance_wait_time_max`` Files old/salt-0.16.1/doc/topics/conventions/.release.rst.swp and new/salt-0.16.2/doc/topics/conventions/.release.rst.swp differ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/doc/topics/pillar/index.rst new/salt-0.16.2/doc/topics/pillar/index.rst --- old/salt-0.16.1/doc/topics/pillar/index.rst 2013-07-29 19:01:28.000000000 +0200 +++ new/salt-0.16.2/doc/topics/pillar/index.rst 2013-08-01 23:39:32.000000000 +0200 @@ -189,8 +189,8 @@ salt '*' saltutil.refresh_pillar -This function triggers the minion to asynchronously refresh the pillar and will always return -``None`` +This function triggers the minion to asynchronously refresh the pillar and will +always return ``None``. Targeting with Pillar ===================== diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/doc/topics/releases/0.16.2.rst new/salt-0.16.2/doc/topics/releases/0.16.2.rst --- old/salt-0.16.1/doc/topics/releases/0.16.2.rst 1970-01-01 01:00:00.000000000 +0100 +++ new/salt-0.16.2/doc/topics/releases/0.16.2.rst 2013-08-01 23:39:32.000000000 +0200 @@ -0,0 +1,225 @@ +========================= +Salt 0.16.2 Release Notes +========================= + +Version 0.16.2 is a bugfix release for 0.16.0, and contains a number of fixes. + +Windows +------- + +- Only allow Administrator's group and SYSTEM user access to C:\\salt. This + eliminates a race condition where a non-admin user could modify a template or + managed file before it is executed by the minion (which is running as an + elevated user), thus avoiding a potential escalation of privileges. (6361_) + +.. _`6361`: https://github.com/saltstack/salt/issues/6361 + +Grains +------ +- Fixed detection of ``virtual`` grain on OpenVZ hardware nodes +- Gracefully handle lsb_release data when it is enclosed in quotes +- Improved grains detection on MacOS + +Pillar +------ +- Don't try to load :doc:`git_pillar </ref/pillar/all/salt.pillar.git_pillar>` + if not enabled in master config (6052_) +- Functions :mod:`pillar.item <salt.modules.pillar.item>` and + :mod:`pillar.items <salt.modules.pillar.items>` added for parity with + :mod:`grains.item <salt.modules.grains.item>`/:mod:`grains.items + <salt.modules.grains.items>`. The old function ``pillar.data`` is preserved + for backwards compatibility. +- Fixed minion traceback when Pillar SLS is malformed (5910_) + +.. _`6052`: https://github.com/saltstack/salt/issues/6052 +.. _`5910`: https://github.com/saltstack/salt/issues/5910 + +Peer Publishing +--------------- +- More gracefully handle improperly quoted publish commands (5958_) +- Fixed traceback when timeout specified via the CLI fo :mod:`publish.publish + <salt.modules.publish.publish>`, :mod:`publish.full_data + <salt.modules.publish.full_data>` (5959_) +- Fixed unintended change in output of :mod:`publish.publish + <salt.modules.publish.publish>` (5928_) + +.. _`5958`: https://github.com/saltstack/salt/issues/5958 +.. _`5959`: https://github.com/saltstack/salt/issues/5959 +.. _`5928`: https://github.com/saltstack/salt/issues/5928 + +Minion +------ +- Fixed salt-key usage in minionswarm script +- Quieted warning about :strong:`SALT_MINION_CONFIG` environment variable on + minion startup and for CLI commands run via ``salt-call`` (5956_) +- Added minion config parameter :conf_minion:`random_reauth_delay` to stagger + re-auth attempts when the minion is waiting for the master to approve its + public key. This helps prevent SYN flooding in larger environments. + +.. _`5956`: https://github.com/saltstack/salt/issues/5956 + +User/Group Management +--------------------- +- Implement previously-ignored ``unique`` option for :mod:`user.present + <salt.states.user.present>` states in FreeBSD +- Report in state output when a :mod:`group.present + <salt.states.group.present>` state attempts to use a gid in use by another + group +- Fixed regression that prevents a :mod:`user.present + <salt.states.user.present>` state to set the password hash to the system + default (i.e. an unset password) +- Fixed multiple :mod:`group.present <salt.states.group.present>` states with +same group (6439_) + +.. _`6439`: https://github.com/saltstack/salt/issues/6439 + +File Management +--------------- +- Fixed file.mkdir setting incorrect permissions (6033_) +- Fixed cleanup of source files for templates when ``/tmp`` is in file_roots + (6118_) +- Fixed caching of zero-byte files when a non-empty file was previously cached + at the same path +- Added HTTP authentication support to the cp module (5641_) +- Diffs are now suppressed when binary files are changed + +.. _`6033`: https://github.com/saltstack/salt/issues/6033 +.. _`6118`: https://github.com/saltstack/salt/issues/6118 +.. _`5641`: https://github.com/saltstack/salt/issues/5641 + +Package/Repository Management +----------------------------- +- Fixed traceback when there is only one target for :mod:`pkg.latest + <salt.states.pkg.latest>` states +- Fixed regression in detection of virtual packages (apt) +- Limit number of pkg database refreshes to once per :mod:`state.sls + <salt.modules.state.sls>`/:mod:`state.highstate + <salt.modules.state.highstate>` +- YUM: Allow 32-bit packages with arches other than i686 to be managed on + 64-bit systems (6299_) +- Fixed incorrect reporting in pkgrepo.managed states (5517_) +- Fixed 32-bit binary package installs on 64-bit RHEL-based distros, and added + proper support for 32-bit packages on 64-bit Debian-based distros (6303_) +- Fixed issue where requisites were inadvertently being put into YUM repo files + (6471_) + +.. _`6299`: https://github.com/saltstack/salt/issues/6299 +.. _`5517`: https://github.com/saltstack/salt/issues/5517 +.. _`6303`: https://github.com/saltstack/salt/issues/6303 +.. _`6471`: https://github.com/saltstack/salt/issues/6471 + +Service Management +------------------ +- Fixed inaccurate reporting of results in :mod:`service.running + <salt.states.service.running>` states when the service fails to start (5894_) +- Fixed handling of custom initscripts in RHEL-based distros so that they are + immediately available, negating the need for a second state run to manage the + service that the initscript controls + +.. _`5894`: https://github.com/saltstack/salt/issues/5894 + +Networking +---------- +- Function network.hwaddr renamed to :mod:`network.hw_addr + <salt.modules.network.hw_addr>` to match :mod:`network.ip_addrs + <salt.modules.network.ip_addrs>` and :mod:`network.ip_addrs6 + <salt.modules.network.ip_addrs6>`. All three functions also now work without + the underscore in the name, as well. +- Fixed traceback in :mod:`bridge.show <salt.modules.bridge.show>` when + interface is not present (6326_) + +.. _`6326`: https://github.com/saltstack/salt/issues/6326 + +SSH +--- +- Fixed incorrect result reporting for some :mod:`ssh_known_hosts.present + <salt.states.ssh_known_hosts.present>` states +- Fixed inaccurate reporting when :mod:`ssh_auth.present + <salt.states.ssh_auth.present>` states are run with ``test=True``, when + rsa/dss is used for the ``enc`` param instead of ssh-rsa/ssh-dss (5374_) + +.. _`5374`: https://github.com/saltstack/salt/issues/5374 + +pip +--- +- Properly handle ``-f`` lines in pip freeze output +- Fixed regression in pip.installed states with specifying a requirements file + (6003_) +- Fixed use of ``editable`` argument in :mod:`pip.installed + <salt.states.pip.installed>` states (6025_) +- Deprecated ``runas`` parameter in execution function calls, in favor of + ``user`` + +.. _`6003`: https://github.com/saltstack/salt/issues/6003 +.. _`6025`: https://github.com/saltstack/salt/issues/6025 + +MySQL +----- +- Allow specification of :doc:`MySQL </ref/modules/all/salt.modules.mysql>` + connection arguments via the CLI, overriding/bypassing minion config params +- Allow :mod:`mysql_user.present <salt.states.mysql_user.present>` states to + set a passwordless login (5550_) +- Fixed endless loop when :mod:`mysql.processlist + <salt.modules.mysql.processlist>` is run (6297_) + +.. _`5550`: https://github.com/saltstack/salt/issues/5550 +.. _`6297`: https://github.com/saltstack/salt/issues/6297 + +PostgreSQL +---------- +- Fixed traceback in :mod:`postgres.user_list + <salt.modules.postgres.user_list>` (6352_) + +.. _`6352`: https://github.com/saltstack/salt/issues/6352 + +Miscellaneous +------------- +- Don't allow :doc:`npm states </ref/states/all/salt.states.npm>` to be used if + :doc:`npm module </ref/modules/all/salt.modules.npm>` is not available +- Fixed :mod:`alternatives.install <salt.states.alternatives.install>` states + for which the target is a symlink (6162_) +- Fixed traceback in :doc:`sysbench module + </ref/modules/all/salt.modules.sysbench>` (6175_) +- Fixed traceback in job cache +- Fixed tempfile cleanup for windows +- Fixed issue where SLS files using the :doc:`pydsl renderer + </ref/renderers/all/salt.renderers.pydsl>` were not being run +- Fixed issue where returners were being passed incorrect information + (5518_) +- Fixed traceback when numeric args are passed to :mod:`cmd.script + <salt.states.cmd.script>` states +- Fixed bug causing :mod:`cp.get_dir <salt.modules.cp.get_dir>` to return more + directories than expected (6048_) +- Fixed traceback when :mod:`supervisord.running + <salt.states.supervisord.running>` states are run with ``test=True`` (6053_) +- Fixed tracebacks when Salt encounters problems running rbenv (5888_) +- Only make the :doc:`monit module </ref/modules/all/salt.modules.monit>` + available if monit binary is present (5871_) +- Fixed incorrect behavior of :mod:`img.mount_image + <salt.modules.img.mount_image>` +- Fixed traceback in :mod:`tomcat.deploy_war <salt.modules.tomcat.deploy_war>` + in Windows +- Don't re-write /etc/fstab if mount fails +- Fixed tracebacks when Salt encounters problems running gem (5886_) +- Fixed incorrect behavior of :mod:`selinux.boolean + <salt.states.selinux.boolean>` states (5912_) +- :doc:`RabbitMQ </ref/states/all/salt.modules.rabbitmq>`: Quote passwords to + avoid symbols being interpolated by the shell (6338_) +- Fixed tracebacks in :mod:`extfs.mkfs <salt.modules.extfs.mkfs>` and + :mod:`extfs.tune <salt.modules.extfs.tune>` (6462_) +- Fixed a regression with the :mod:`module.run <salt.states.module.run>` state + where the ``m_name`` and ``m_fun`` arguments were being ignored (6464_) + +.. _`6162`: https://github.com/saltstack/salt/issues/6162 +.. _`6175`: https://github.com/saltstack/salt/issues/6175 +.. _`5518`: https://github.com/saltstack/salt/issues/5518 +.. _`6048`: https://github.com/saltstack/salt/issues/6048 +.. _`6053`: https://github.com/saltstack/salt/issues/6053 +.. _`5888`: https://github.com/saltstack/salt/issues/5888 +.. _`5871`: https://github.com/saltstack/salt/issues/5871 +.. _`5886`: https://github.com/saltstack/salt/issues/5886 +.. _`5912`: https://github.com/saltstack/salt/issues/5912 +.. _`6338`: https://github.com/saltstack/salt/issues/6338 +.. _`6462`: https://github.com/saltstack/salt/issues/6462 +.. _`6464`: https://github.com/saltstack/salt/issues/6464 + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/doc/topics/tutorials/walkthrough.rst new/salt-0.16.2/doc/topics/tutorials/walkthrough.rst --- old/salt-0.16.1/doc/topics/tutorials/walkthrough.rst 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/doc/topics/tutorials/walkthrough.rst 2013-08-01 23:39:32.000000000 +0200 @@ -192,7 +192,7 @@ On the minion:: - # cat /etc/salt/pkg/minion/minion.pub + # cat /etc/salt/pki/minion/minion.pub -----BEGIN PUBLIC KEY----- MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA0JcA0IEp/yqghK5V2VLM jbG7FWV6qtw/ubTDBnpDGQgrvSNOtd0QcJsAzAtDcHwrudQgyxTZGVJqPY7gLc7P diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/cli/caller.py new/salt-0.16.2/salt/cli/caller.py --- old/salt-0.16.1/salt/cli/caller.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/cli/caller.py 2013-08-01 23:39:32.000000000 +0200 @@ -52,9 +52,7 @@ ret = {} fun = self.opts['fun'] ret['jid'] = '{0:%Y%m%d%H%M%S%f}'.format(datetime.datetime.now()) - proc_fn = os.path.join( - salt.minion.get_proc_dir(self.opts['cachedir']), - ret['jid']) + proc_fn = os.path.join(self.opts['cachedir'], 'proc', ret['jid']) if fun not in self.minion.functions: sys.stderr.write('Function {0} is not available\n'.format(fun)) sys.exit(-1) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/fileserver/gitfs.py new/salt-0.16.2/salt/fileserver/gitfs.py --- old/salt-0.16.1/salt/fileserver/gitfs.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/fileserver/gitfs.py 2013-08-01 23:39:32.000000000 +0200 @@ -14,6 +14,7 @@ import time import hashlib import logging +import distutils # Import third party libs HAS_GIT = False @@ -27,6 +28,7 @@ import salt.utils import salt.fileserver + log = logging.getLogger(__name__) @@ -42,7 +44,12 @@ log.error('Git fileserver backend is enabled in configuration but ' 'could not be loaded, is GitPython installed?') return False - if not git.__version__ > '0.3.0': + gitver = distutils.version.LooseVersion(git.__version__) + minver = distutils.version.LooseVersion('0.3.0') + if gitver < minver: + log.error('Git fileserver backend is enabled in configuration but ' + 'GitPython version is not greater than 0.3.0, ' + 'version {0} detected'.format(git.__version__)) return False return 'git' @@ -179,19 +186,17 @@ short = 'master' dest = os.path.join(__opts__['cachedir'], 'gitfs/refs', short, path) hashes_glob = os.path.join(__opts__['cachedir'], - 'gitfs/hash', - short, - '{0}.hash.*'.format(path)) - blobshadest = os.path.join( - __opts__['cachedir'], - 'gitfs/hash', - short, - '{0}.hash.blob_sha1'.format(path)) - lk_fn = os.path.join( - __opts__['cachedir'], - 'gitfs/hash', - short, - '{0}.lk'.format(path)) + 'gitfs/hash', + short, + '{0}.hash.*'.format(path)) + blobshadest = os.path.join(__opts__['cachedir'], + 'gitfs/hash', + short, + '{0}.hash.blob_sha1'.format(path)) + lk_fn = os.path.join(__opts__['cachedir'], + 'gitfs/hash', + short, + '{0}.lk'.format(path)) destdir = os.path.dirname(dest) hashdir = os.path.dirname(blobshadest) if not os.path.isdir(destdir): @@ -281,11 +286,11 @@ short = 'master' relpath = fnd['rel'] path = fnd['path'] - hashdest = os.path.join( - __opts__['cachedir'], - 'gitfs/hash', - short, - '{0}.hash.{1}'.format(relpath, __opts__['hash_type'])) + hashdest = os.path.join(__opts__['cachedir'], + 'gitfs/hash', + short, + '{0}.hash.{1}'.format(relpath, + __opts__['hash_type'])) if not os.path.isfile(hashdest): with salt.utils.fopen(path, 'rb') as fp_: ret['hsum'] = getattr(hashlib, __opts__['hash_type'])( diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/grains/core.py new/salt-0.16.2/salt/grains/core.py --- old/salt-0.16.1/salt/grains/core.py 2013-07-29 19:01:28.000000000 +0200 +++ new/salt-0.16.2/salt/grains/core.py 2013-08-01 23:39:32.000000000 +0200 @@ -281,10 +281,9 @@ grains = dict([(k, __salt__['cmd.run'](v)) for k, v in cmds.items()]) - if grains['cpu_flags'] and not isinstance(grains['cpu_flags'], list): + if 'cpu_flags' in grains and isinstance(grains['cpu_flags'], basestring): grains['cpu_flags'] = grains['cpu_flags'].split(' ') - if osdata['kernel'] == 'NetBSD': grains['cpu_flags'] = [] for line in __salt__['cmd.run']('cpuctl identify 0').splitlines(): @@ -884,6 +883,8 @@ # Load the virtual machine info grains.update(_virtual(grains)) grains.update(_ps(grains)) + if grains['os_family'] == "RedHat": + grains['osmajorrelease'] = grains['osrelease'].split('.', 1) return grains diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/modules/apt.py new/salt-0.16.2/salt/modules/apt.py --- old/salt-0.16.1/salt/modules/apt.py 2013-07-27 00:15:45.000000000 +0200 +++ new/salt-0.16.2/salt/modules/apt.py 2013-08-01 23:39:32.000000000 +0200 @@ -231,6 +231,10 @@ software repository. To install a package file manually, use the "sources" option. + 32-bit packages can be installed on 64-bit systems by appending the + architecture designation (``:i386``, etc.) to the end of the package + name. + CLI Example:: salt '*' pkg.install <package name> @@ -269,6 +273,10 @@ with the keys being package names, and the values being the source URI or local path to the package. + 32-bit packages can be installed on 64-bit systems by appending the + architecture designation (``:i386``, etc.) to the end of the package + name. + CLI Example:: salt '*' pkg.install sources='[{"foo": "salt://foo.deb"},{"bar": "salt://bar.deb"}]' @@ -509,7 +517,7 @@ ret = {'installed': {}, 'removed': {}} cmd = 'dpkg-query --showformat=\'${Status} ${Package} ' \ - '${Version}\n\' -W' + '${Version} ${Architecture}\n\' -W' out = __salt__['cmd.run_all'](cmd).get('stdout', '') # Typical lines of output: @@ -518,10 +526,13 @@ for line in out.splitlines(): cols = line.split() try: - linetype, status, name, version_num = \ - [cols[x] for x in (0, 2, 3, 4)] + linetype, status, name, version_num, arch = \ + [cols[x] for x in (0, 2, 3, 4, 5)] except ValueError: continue + if __grains__.get('cpuarch', '') == 'x86_64' \ + and re.match(r'i\d86', arch): + name += ':{0}'.format(arch) if len(cols): if ('install' in linetype or 'hold' in linetype) and \ 'installed' in status: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/modules/extfs.py new/salt-0.16.2/salt/modules/extfs.py --- old/salt-0.16.1/salt/modules/extfs.py 2013-06-14 19:12:46.000000000 +0200 +++ new/salt-0.16.2/salt/modules/extfs.py 2013-08-01 23:39:32.000000000 +0200 @@ -85,12 +85,13 @@ 'uuid': 'U'} opts = '' - for key in kwargs.keys(): - opt = kwarg_map[key] - if kwargs[key] == 'True': - opts += '-{0} '.format(opt) - else: - opts += '-{0} {1} '.format(opt, kwargs[key]) + for key in kwargs: + if key in kwarg_map: + opt = kwarg_map[key] + if kwargs[key] == 'True': + opts += '-{0} '.format(opt) + else: + opts += '-{0} {1} '.format(opt, kwargs[key]) cmd = 'mke2fs -F -t {0} {1}{2}'.format(fs_type, opts, device) out = __salt__['cmd.run'](cmd).splitlines() ret = [] @@ -166,12 +167,13 @@ 'user': 'u', 'uuid': 'U'} opts = '' - for key in kwargs.keys(): - opt = kwarg_map[key] - if kwargs[key] == 'True': - opts += '-{0} '.format(opt) - else: - opts += '-{0} {1} '.format(opt, kwargs[key]) + for key in kwargs: + if key in kwarg_map: + opt = kwarg_map[key] + if kwargs[key] == 'True': + opts += '-{0} '.format(opt) + else: + opts += '-{0} {1} '.format(opt, kwargs[key]) cmd = 'tune2fs {0}{1}'.format(opts, device) out = __salt__['cmd.run'](cmd).splitlines() return out diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/modules/pkg_resource.py new/salt-0.16.2/salt/modules/pkg_resource.py --- old/salt-0.16.1/salt/modules/pkg_resource.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/modules/pkg_resource.py 2013-08-01 23:39:32.000000000 +0200 @@ -3,13 +3,15 @@ ''' # Import python libs +import collections +import distutils.version # pylint: disable=E0611 import fnmatch +import logging import os +import pprint import re +import sys import yaml -import pprint -import logging -import distutils.version # Import salt libs import salt.utils @@ -23,30 +25,22 @@ version number. ''' def parse_rpm(path): - name = '' - version = '' - rel = '' - result = __salt__['cmd.run_all']('rpm -qpi "{0}"'.format(path)) - if result['retcode'] == 0: - for line in result['stdout'].splitlines(): - if not name: - match = re.match(r'^Name\s*:\s*(\S+)', line) - if match: - name = match.group(1) - continue - if not version: - match = re.match(r'^Version\s*:\s*(\S+)', line) - if match: - version = match.group(1) - continue - if not rel: - match = re.match(r'^Release\s*:\s*(\S+)', line) - if match: - rel = match.group(1) - continue - if rel: - version += '-{0}'.format(rel) - return name, version + try: + from salt.modules.yumpkg5 import __QUERYFORMAT, _parse_pkginfo + from salt.utils import namespaced_function + _parse_pkginfo = namespaced_function(_parse_pkginfo, globals()) + except ImportError: + log.critical('Error importing helper functions. This is almost ' + 'certainly a bug.') + return '', '' + pkginfo = __salt__['cmd.run_all']( + 'rpm -qp --queryformat {0!r} {1!r}'.format(__QUERYFORMAT, path) + ).get('stdout', '').strip() + pkginfo = _parse_pkginfo(pkginfo) + if pkginfo is None: + return '', '' + else: + return pkginfo.name, pkginfo.version def parse_pacman(path): name = '' @@ -69,19 +63,42 @@ def parse_deb(path): name = '' version = '' + arch = '' + # This is ugly, will have to try to find a better way of accessing the + # __grains__ global. + cpuarch = sys.modules[ + __salt__['test.ping'].__module__ + ].__grains__.get('cpuarch', '') + result = __salt__['cmd.run_all']('dpkg-deb -I "{0}"'.format(path)) if result['retcode'] == 0: for line in result['stdout'].splitlines(): if not name: - match = re.match(r'^\s*Package\s*:\s*(\S+)', line) - if match: - name = match.group(1) + try: + name = re.match( + r'^\s*Package\s*:\s*(\S+)', + line + ).group(1) + except AttributeError: continue if not version: - match = re.match(r'^\s*Version\s*:\s*(\S+)', line) - if match: - version = match.group(1) + try: + version = re.match( + r'^\s*Version\s*:\s*(\S+)', + line + ).group(1) + except AttributeError: + continue + if cpuarch == 'x86_64' and not arch: + try: + arch = re.match( + r'^\s*Architecture\s*:\s*(\S+)', + line + ).group(1) + except AttributeError: continue + if arch: + name += ':{0}'.format(arch) return name, version if __grains__['os_family'] in ('Suse', 'RedHat', 'Mandriva'): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/modules/rabbitmq.py new/salt-0.16.2/salt/modules/rabbitmq.py --- old/salt-0.16.1/salt/modules/rabbitmq.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/modules/rabbitmq.py 2013-08-01 23:39:32.000000000 +0200 @@ -103,7 +103,7 @@ salt '*' rabbitmq.add_user rabbit_user password ''' res = __salt__['cmd.run']( - 'rabbitmqctl add_user {0} {1}'.format(name, password), + 'rabbitmqctl add_user {0} \'{1}\''.format(name, password), runas=runas) msg = 'Added' @@ -134,7 +134,7 @@ salt '*' rabbitmq.change_password rabbit_user password ''' res = __salt__['cmd.run']( - 'rabbitmqctl change_password {0} {1}'.format(name, password), + 'rabbitmqctl change_password {0} \'{1}\''.format(name, password), runas=runas) msg = 'Password Changed' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/modules/saltutil.py new/salt-0.16.2/salt/modules/saltutil.py --- old/salt-0.16.1/salt/modules/saltutil.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/modules/saltutil.py 2013-08-01 23:39:32.000000000 +0200 @@ -293,14 +293,14 @@ salt '*' saltutil.sync_all ''' - logging.debug('Syncing all') - ret = [] - ret.append(sync_modules(env, False)) - ret.append(sync_states(env, False)) - ret.append(sync_grains(env, False)) - ret.append(sync_renderers(env, False)) - ret.append(sync_returners(env, False)) - ret.append(sync_outputters(env, False)) + log.debug('Syncing all') + ret = {} + ret['modules'] = sync_modules(env, False) + ret['states'] = sync_states(env, False) + ret['grains'] = sync_grains(env, False) + ret['renderers'] = sync_renderers(env, False) + ret['returners'] = sync_returners(env, False) + ret['outputters'] = sync_outputters(env, False) if refresh: refresh_modules() return ret diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/modules/yumpkg5.py new/salt-0.16.2/salt/modules/yumpkg5.py --- old/salt-0.16.1/salt/modules/yumpkg5.py 2013-07-27 00:15:45.000000000 +0200 +++ new/salt-0.16.2/salt/modules/yumpkg5.py 2013-08-01 23:39:32.000000000 +0200 @@ -16,6 +16,8 @@ log = logging.getLogger(__name__) +# This is imported in salt.modules.pkg_resource._parse_pkg_meta. Don't change +# it without considering its impact there. __QUERYFORMAT = '%{NAME}_|-%{VERSION}_|-%{RELEASE}_|-%{ARCH}' @@ -60,6 +62,8 @@ return False +# This is imported in salt.modules.pkg_resource._parse_pkg_meta. Don't change +# it without considering its impact there. def _parse_pkginfo(line): ''' A small helper to parse package information; returns a namedtuple diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/payload.py new/salt-0.16.2/salt/payload.py --- old/salt-0.16.1/salt/payload.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/payload.py 2013-08-01 23:39:32.000000000 +0200 @@ -121,8 +121,15 @@ # This means iterating through all elements of a dictionary or # list/tuple def odict_encoder(obj): - if isinstance(obj, OrderedDict): + if isinstance(obj, dict): + for key, value in obj.copy().iteritems(): + obj[key] = odict_encoder(value) return dict(obj) + elif isinstance(obj, (list, tuple)): + obj = list(obj) + for idx, entry in enumerate(obj): + obj[idx] = odict_encoder(entry) + return obj return obj if isinstance(msg, dict): @@ -132,6 +139,7 @@ msg = list(msg) for idx, entry in enumerate(msg): msg[idx] = odict_encoder(entry) + return msgpack.dumps(msg) def dump(self, msg, fn_): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/state.py new/salt-0.16.2/salt/state.py --- old/salt-0.16.1/salt/state.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/state.py 2013-08-01 23:39:32.000000000 +0200 @@ -28,7 +28,7 @@ import salt.pillar import salt.fileclient import salt.utils.event -from salt._compat import string_types, callable +from salt._compat import string_types from salt.template import compile_template, compile_template_str from salt.exceptions import SaltReqTimeoutError, SaltException diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/states/group.py new/salt-0.16.2/salt/states/group.py --- old/salt-0.16.1/salt/states/group.py 2013-07-27 00:15:45.000000000 +0200 +++ new/salt-0.16.2/salt/states/group.py 2013-08-01 23:39:32.000000000 +0200 @@ -13,6 +13,9 @@ - system: True ''' +# Import python libs +import sys + def present(name, gid=None, system=False): ''' @@ -52,6 +55,10 @@ 'be changed to {1}').format(name, gid) return ret ret['result'] = __salt__['group.chgid'](name, gid) + # Clear cached group data + sys.modules[ + __salt__['test.ping'].__module__ + ].__context__.pop('group.getent', None) if ret['result']: ret['comment'] = ('Changed gid to {0} for group {1}' .format(gid, name)) @@ -64,20 +71,20 @@ else: ret['comment'] = 'Group {0} is already present'.format(name) return ret - + # Group is not present, test if gid is free - if gid != None: + if gid is not None: gid_group = None for lgrp in grps: if lgrp['gid'] == gid: gid_group = lgrp['name'] break - if gid_group != None: + if gid_group is not None: ret['result'] = False ret['comment'] = ('Group {0} is not present but gid {1}' ' is already taken by group {2}' - ).format(name,gid,gid_group) + .format(name, gid, gid_group)) return ret # Group is not present, make it! @@ -86,7 +93,13 @@ ret['comment'] = ('Group {0} is not present and should be created' ).format(name) return ret + ret['result'] = __salt__['group.add'](name, gid, system) + # Clear cached group data + sys.modules[ + __salt__['test.ping'].__module__ + ].__context__.pop('group.getent', None) + if ret['result']: ret['changes'] = __salt__['group.info'](name) ret['comment'] = 'Added group {0}'.format(name) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/states/module.py new/salt-0.16.2/salt/states/module.py --- old/salt-0.16.1/salt/states/module.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/states/module.py 2013-08-01 23:39:32.000000000 +0200 @@ -104,11 +104,11 @@ rarg = 'm_fun' else: rarg = arg - if rarg not in kwargs and rarg not in defaults: + if rarg not in kwargs and arg not in defaults: missing.add(rarg) continue - if rarg in defaults: - args.append(defaults[rarg]) + if arg in defaults: + args.append(defaults[arg]) else: args.append(kwargs.pop(rarg)) if missing: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/states/pkgrepo.py new/salt-0.16.2/salt/states/pkgrepo.py --- old/salt-0.16.1/salt/states/pkgrepo.py 2013-07-27 00:15:45.000000000 +0200 +++ new/salt-0.16.2/salt/states/pkgrepo.py 2013-08-01 23:39:32.000000000 +0200 @@ -176,7 +176,8 @@ elif kwarg == 'humanname': repokwargs['name'] = kwargs[kwarg] elif kwarg in ('__id__', 'fun', 'state', '__env__', '__sls__', - 'order'): + 'order', 'watch', 'watch_in', 'require', 'require_in', + 'prereq', 'prereq_in'): pass else: repokwargs[kwarg] = kwargs[kwarg] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/utils/parsers.py new/salt-0.16.2/salt/utils/parsers.py --- old/salt-0.16.1/salt/utils/parsers.py 2013-07-29 18:29:33.000000000 +0200 +++ new/salt-0.16.2/salt/utils/parsers.py 2013-08-01 23:39:32.000000000 +0200 @@ -162,7 +162,7 @@ ) if self.config.get('conf_file', None) is not None: - logging.getLogger(__name__).info( + logging.getLogger(__name__).debug( 'Configuration file path: {0}'.format( self.config['conf_file'] ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt/version.py new/salt-0.16.2/salt/version.py --- old/salt-0.16.1/salt/version.py 2013-07-29 19:16:31.000000000 +0200 +++ new/salt-0.16.2/salt/version.py 2013-08-01 23:39:46.000000000 +0200 @@ -6,7 +6,7 @@ import sys -__version_info__ = (0, 16, 1) +__version_info__ = (0, 16, 2) __version__ = '.'.join(map(str, __version_info__)) GIT_DESCRIBE_REGEX = ( diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt.egg-info/PKG-INFO new/salt-0.16.2/salt.egg-info/PKG-INFO --- old/salt-0.16.1/salt.egg-info/PKG-INFO 2013-07-29 19:21:15.000000000 +0200 +++ new/salt-0.16.2/salt.egg-info/PKG-INFO 2013-08-01 23:42:20.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: salt -Version: 0.16.1 +Version: 0.16.2 Summary: Portable, distributed, remote execution and configuration management system Home-page: http://saltstack.org Author: Thomas S Hatch diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/salt-0.16.1/salt.egg-info/SOURCES.txt new/salt-0.16.2/salt.egg-info/SOURCES.txt --- old/salt-0.16.1/salt.egg-info/SOURCES.txt 2013-07-29 19:21:15.000000000 +0200 +++ new/salt-0.16.2/salt.egg-info/SOURCES.txt 2013-08-01 23:42:20.000000000 +0200 @@ -451,7 +451,6 @@ doc/topics/hacking.rst doc/topics/index.rst doc/topics/nonroot.rst -doc/topics/conventions/.release.rst.swp doc/topics/conventions/index.rst doc/topics/conventions/release.rst doc/topics/conventions/style.rst @@ -495,6 +494,7 @@ doc/topics/releases/0.15.0.rst doc/topics/releases/0.15.1.rst doc/topics/releases/0.16.0.rst +doc/topics/releases/0.16.2.rst doc/topics/releases/0.6.0.rst doc/topics/releases/0.7.0.rst doc/topics/releases/0.8.0.rst -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org