Commit Graph

68827 Commits

Author SHA1 Message Date
Justin Findlay
117d641830 tests.integration: fix 4230c8a 2016-04-08 16:54:00 -06:00
Nicole Thomas
b29983529f Issue #28706: Fix state user.present behavior. (#32448)
- As mentionned in issue #28706, state user.present no longer remove
      user from groups if the keyword 'groups' with empty value '[]' is not
      explicitly set, salt will assume current groups are still wanted.
2016-04-08 16:32:26 -06:00
Eric Radman
517786873b Use reload_module from six for compatibility with Python3 (#32438)
reload() was moved to importlib in 3.4
2016-04-08 16:01:18 -06:00
Justin Findlay
fa8d030ab7 tests.integration: bypass MacOS TMPDIR, gettempdir (#32447)
Updates 0edd532, 8f558a5.

When logging in as root over `ssh root@host`, `$TMPDIR` and
`tempfile.gettempdir()` are both set to a variation of:
```
/private/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/
```
When logging in as root over `sudo -i`, `$TMPDIR` is unset and
`tempfile.gettempdir()` is set to `/tmp`.

My guess is that the second case is an unintended or uncorrected omision
by Apple as they have introduced the longer, randomized temp path in a
recent version of MacOS.
2016-04-08 16:00:48 -06:00
Nicole Thomas
cef33d5fad Argument name in docs should match actual arg name (#32445)
Fixes #31851
2016-04-08 16:00:27 -06:00
Justin Anderson
116c91e293 Changed the target file in file.symlink test (#32443) 2016-04-08 16:00:15 -06:00
Mike Place
74d0fa06b4 Pass parser options into batch mode
Resolves #31738
2016-04-08 15:56:03 -06:00
Nicole Thomas
49af98b7a7 Merge pull request #32431 from rallytime/merge-develop
[develop] Merge forward from 2016.3 to develop
2016-04-08 11:17:28 -06:00
rallytime
d942c38cb1 Removed useless slack_notify unit tests 2016-04-08 11:13:14 -06:00
Nicole Thomas
8d44aa3f08 Merge pull request #32429 from rallytime/merge-2016.3
[2016.3] Merge forward from 2015.8 to 2016.3
2016-04-08 10:56:12 -06:00
Eric Radman
2d9f8ab27e Skip PAM test on OpenBSD (#32439)
Will always fail since OpenBSD does not have have PAM
2016-04-08 10:19:41 -06:00
Nicole Thomas
6a88b5ef29 Merge pull request #32422 from eradman/env_test
Do not assume temporary files have the user's gid
2016-04-08 10:16:50 -06:00
Nicole Thomas
b9121176ab Merge pull request #32428 from jtand/timezone_test_fix
Fix issue that #32420 exposed in timezone_test
2016-04-08 10:16:05 -06:00
Nicole Thomas
7472141b7d Merge pull request #32437 from rallytime/pgjson_queue_docs
Add pgjsonb_queue to queue doc index
2016-04-08 10:14:40 -06:00
Nicole Thomas
a36f9499fc Merge pull request #32432 from ticosax/fix-domainname-introspection
[dockerng] Fix Domainname introspection
2016-04-08 10:12:19 -06:00
rallytime
7f8eb751a0 Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/cli/daemons.py
  - salt/modules/win_servermanager.py
  - tests/unit/modules/win_servermanager_test.py
2016-04-08 10:09:03 -06:00
rallytime
5a641ddc2a Pylint fixes 2016-04-08 09:56:03 -06:00
Nicole Thomas
def911974c Merge pull request #32427 from rallytime/merge-2015.8
[2015.8] Merge forward from 2015.5 to 2015.8
2016-04-08 09:39:13 -06:00
rallytime
1fa7c021b3 Add pgjsonb_queue to queue doc index 2016-04-08 09:08:17 -06:00
Nicolas Delaby
505b5b0168 Fix Domainname introspection
Default value needs to be extracted from the container itself,
because dockerd set Domainname value when network_mode=host.
2016-04-08 11:02:05 +02:00
Eric Radman
504cc02741 Do not assume temporary files have the user's gid
On BSD-like systems (including MacOS) files created in /tmp (or any dir
with mod 1777) do not have the user's group. Therefore the st_gid for
files created in /tmp will usually be wheel. Easiest thing to do is to
skip this test.
2016-04-07 22:32:33 -04:00
rallytime
59b804d230 Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/modules/pkgng.py
  - salt/modules/status.py
  - salt/states/boto_asg.py
  - salt/states/boto_elb.py
2016-04-07 16:28:59 -06:00
Justin Anderson
ec284fdff4 Fix issue that #32420 exposed in timezone_test 2016-04-07 16:19:27 -06:00
Nicole Thomas
c712fbed37 Merge pull request #32419 from jtand/file_state_test_fix
Fixes test failure where Fedora 23 has /etc/grub.conf by default
2016-04-07 16:15:51 -06:00
rallytime
9531ea6ef5 Merge branch '2015.5' into '2015.8'
Conflicts:
  - doc/topics/highavailability/index.rst
  - salt/loader.py
  - salt/modules/service.py
  - salt/states/cmd.py
  - tests/unit/states/cmd_test.py
2016-04-07 16:10:32 -06:00
Nicole Thomas
5bc8c326ce Merge pull request #32423 from jtand/glusterfs_test_fix
Update glusterfs_test to be inline with #32312
2016-04-07 15:53:03 -06:00
Nicole Thomas
c07e02bacb Merge pull request #32425 from cachedout/issue_31632
Fix salt-cloud paralell provisioning
2016-04-07 15:52:06 -06:00
Eric Radman
90b0a42a21 Unbreak cron.file (#32396)
* Unbreak cron.file

An extra argument (skip_verify) was recently added to get_managed(),
resulting in this error:

  Unable to manage file: get_managed() takes exactly 11 arguments (10 given)

Also eliminate a variable that can remain uninitialized when running
`salt-call`

* Correct pylint error
2016-04-07 14:56:09 -06:00
Eric Radman
b220b4dd98 Unbreak timezone test for Gentoo (#32420)
Gentoo and Debian both use use /etc/timezone

See https://wiki.gentoo.org/wiki/System_time
2016-04-07 14:55:51 -06:00
Nicole Thomas
0809126d8e Merge #32293 with test fixes (#32418)
* Fix issue #11497

* Remove check for working directory presence in tests
2016-04-07 14:55:25 -06:00
Erik Johnson
bbd8260a42 Ignore Raspbian in service.py __virtual__ (#32421)
* Ignore Raspbian in service.py __virtual__

This prevents more than one execution module from trying to load as the
service virtual module.

Refs: #32413

* pack __salt__ before loading provider overrides

We can (and should) pack here since we're just packing a reference to the
object. __salt__ needs to be available when we're loading our provider
overrides

* Fix broken __salt__ dict in provider override

Using ret.items() here sets ``__salt__`` to its items (tuple containing
function name and reference), breaking usage of ``__salt__`` inside
overridden functions.
2016-04-07 14:54:38 -06:00
Mike Place
127c0829ee Fix salt-cloud paralell provisioning
Closes #31632
2016-04-07 14:50:35 -06:00
Justin Anderson
6f98bd50eb Update glusterfs_test to be inline with #32312 2016-04-07 14:38:21 -06:00
Justin Anderson
28ea60f28e Fixes test failure where Fedora 23 has /etc/grub.conf by default 2016-04-07 11:40:12 -06:00
James O'Neill
c2442ad46f Discard duplicate YAML nodes when merging anchors to avoid duplicate … (#32042)
* Discard duplicate YAML nodes when merging anchors to avoid duplicate node errors. Add yamlloader unit tests.

Fixed #14550 Using YAML anchors/references in Pillars causes conflicting IDs

* Fix lint errors. Make external function a static method.

* Fix remaining lint errors in unit test file.
2016-04-07 10:27:20 -06:00
skizunov
bdc34c028a PY3: Fix trim_dict to work with use_bin_type (#32406)
salt/utils/dicttrim.py:

- Changed `salt.utils.dicttrim.trim_dict` to take an extra parameter

`use_bin_type`. Hence, when handling this data, it will decode

using `encoding='utf-8'` and encode using `use_bin_type=True`.



salt/utils/event.py:

- Since events use `use_bin_type=True` for Python 3, when calling

`salt.utils.dicttrim.trim_dict` set `use_bin_type=six.PY3`



salt/minion.py:

- Minion._process_beacons also uses `salt.utils.dicttrim.trim_dict`.

However, it doesn't seem to be referenced anywhere, so it has been

removed entirely. It wasn't PY3 compliant for other reasons anyway.

Surprisingly, `salt.utils.dicttrim` wasn't even imported in

minion.py to begin with.



Signed-off-by: Sergey Kizunov <sergey.kizunov@ni.com>
2016-04-07 10:24:49 -06:00
Erik Johnson
005825a30e Merge pull request #32416 from jtand/salt_spec_fix
Updated salt.spec bash_completion
2016-04-07 11:17:19 -05:00
skizunov
1f8983c7d5 TCP Load balancer for Windows Python 3 (#32401)
This will add load balancer functionality to the salt-master

when running on Windows Python 3. Unfortunately, on Python 2, the

limit for `worker_threads` remains 1 due to a lack of needed

functionality in Python 2. See issue #27367 for details.



salt/master.py:

- Modified the `tcp_only` check to only issue the warning if we are

using Windows Python 2 and `worker_threads` is not already set to 1.



salt/transport/tcp.py:

- Added global `USE_LOAD_BALANCER` to tell if we need to add the

extra load balancer functionality. Currently, it will be set if

we are using Windows and Python 3.

- Added `LoadBalancerServer`. This runs in its own process and will

listen for incoming connections. Each incoming connection will be

sent via multiprocessing queue to the workers. Since the queue is shared

amongst workers, only one worker will handle a given connection.

- Added `LoadBalancerWorker`. This inherits from `SaltMessageServer`

and is used in its place for `TCPReqServerChannel.req_server` when

`USE_LOAD_BALANCER` is True. It adds the additional functionality of

getting connections from the shared multiprocessing queue that

`LoadBalancerServer` sends connections to and processes those

connections.



Signed-off-by: Sergey Kizunov <sergey.kizunov@ni.com>
2016-04-07 10:00:19 -06:00
Moises Silva
d47f6cbc04 Improve Key.gen_keys() method to be more flexible and have better defaults (#32380)
* Allow passing extra keyword arguments to tweak the key generation

  process through the API without requiring special options to be

  present in the minion configuration options.



* Default the key generation directory to pki_dir when gen_keys_dir

  is not provided rather than failing with a KeyError exception.



* Default the keyname to 'minion' if no gen_keys option was provided.



* Return the fingerprint of the generated pub key.



Generating keys for a minion programatically with the default minion

configuration can now be done simply doing:



from salt.config import minion_config

from salt.key import Key



Key(minion_config(None)).gen_keys()



This will return the generated key fingerprint.



Note that the implementation for RaetKey has a significantly different

interface despite its inherited behavior from the Key class. An effort

was made to make the interface as close as possible, but, it does

not generate a PKI key pair for example, and no fingerprint is

returned when calling gen_keys().
2016-04-07 09:48:02 -06:00
Justin Findlay
b27ccc424b update release candidate testing doc (#32414) 2016-04-07 09:41:46 -06:00
Moe
65e53afc19 Add vdir functionality to win_iis (#32403) 2016-04-07 09:36:04 -06:00
Justin Anderson
65614b7f0f Updated salt.spec bash_completion 2016-04-07 09:16:47 -06:00
Andres Montalban
690addf0b4 FreeBSD supports packages in format java/openjdk7 so the prior commit broke that functionality. Check freebsd/pkg#1409 for more info. 2016-04-07 09:11:54 -06:00
Andres Montalban
51fb2ac4c7 FreeBSD supports packages in format java/openjdk7 so the prior commit broke that functionality. Check freebsd/pkg#1409 for more info. 2016-04-07 09:11:42 -06:00
Erik Johnson
709410ada3 Improve git_pillar documentation/logging
* Add note about different behavior of top file in git_pillar

* Make log entry for a missing pillar SLS file more accurate for git_pillar
2016-04-07 09:10:53 -06:00
Nicole Thomas
c53efc3349 Update master config docs 2016-04-07 09:10:19 -06:00
Nicole Thomas
b80be476e7 Merge pull request #32408 from toddtomkinson/fix_fetch_uri_mismatch
remove "duplicate" fetch array when updating a marathon app
2016-04-07 09:05:03 -06:00
Erik Johnson
2cc054bbc0 Merge pull request #32323 from mcalmer/fix-ensure-installed-latest-with-attributes
fix sorting by latest version when called with an attribute
2016-04-07 01:24:35 -05:00
Todd Tomkinson
d7f196808d remove "duplicate" fetch array when updating a marathon app
fixes mesosphere/marathon#3054 for the marathon module by implementing
the same fix used in the marathon ui
2016-04-06 22:30:22 -06:00
Erik Johnson
7e1d218469 Merge pull request #32398 from rallytime/config-default-change
Change some config defaults in the Carbon release
2016-04-06 19:23:04 -05:00