Commit Graph

5853 Commits

Author SHA1 Message Date
Thomas S Hatch
d9c086fac9 Merge pull request #1782 from mrud/mru/upstart
Mru/upstart
2012-08-06 22:32:50 -07:00
Ulrich Dangel
f7de4b74f4 Simplify upstart definitions
* Remove unecessary script stanzas
* Remove explicit interpreter
* Run salt-master in the foreground
2012-08-07 06:39:06 +02:00
Ulrich Dangel
218a0bd35d Change upstart definition to respawn minions as well as syndic and limit master respawning. 2012-08-07 06:37:58 +02:00
Thomas S Hatch
549e3bf651 Merge pull request #1779 from s0undt3ch/no-more-os.sep.join
Stop using `os.sep.join` to join paths.
2012-08-06 16:50:40 -07:00
Pedro Algarvio
8fba9a2b47 Stop using os.sep.join to join paths.
Python has a specific function to join paths for a reason. Let's see some examples why:
```python
>>> import os
>>> p1 = '/'
>>> p2 = 'foo'
>>> os.path.join(p1, p2)
'/foo'
>>> os.sep.join([p1, p2])
'//foo'
>>> p2 = '/foo'
>>> os.sep.join([p1, p2])
'///foo'
>>> os.path.normpath(os.sep.join([p1, p2]))
'/foo'
>>> p2 = 'foo'
>>> os.path.normpath(os.sep.join([p1, p2]))
'//foo'
>>> p2 = '/foo'
>>> os.path.join(p1, p2)
'/foo'
>>>
```

Also, python docs also state the knowing the OS separator is not always enough to parse/join paths, see http://docs.python.org/library/os#os.sep

There are some posts on the internet which state that `os.sep.join` is faster that `os.path.join`, and, most likely it is, but is it THAT faster? Does that really make a difference in salt's context, specially since it's error prone as shown above?
2012-08-07 00:24:42 +01:00
Pedro Algarvio
0b73795310 Merge branch 'develop' of git://github.com/saltstack/salt into develop 2012-08-06 23:05:37 +01:00
Thomas S Hatch
654fbfe065 Merge pull request #1778 from scott-w/develop
Develop
2012-08-06 14:11:32 -07:00
Pedro Algarvio
2a7e9500d7 Set the master's logfile to avoid travis failing. 2012-08-06 17:58:30 +01:00
Thomas S Hatch
3f489d4622 Merge pull request #1774 from bretep/feature/network_state-bridge-bypassfirewall
Normalize quoting
2012-08-06 08:49:49 -07:00
Bret Palsson
dd366699df Normalize quoting 2012-08-06 09:44:34 -06:00
Thomas S Hatch
2128567276 Merge pull request #1773 from paulcollinsiii/pip_logging
Fix log option in pip module
2012-08-06 01:10:13 -07:00
Thomas S Hatch
4cfc711550 Merge pull request #1771 from s0undt3ch/dotted-loaded-module-names
Improved the salt loader names for log filtering.
2012-08-06 01:05:50 -07:00
Thomas S Hatch
2355dc3dd4 Merge pull request #1770 from s0undt3ch/master
Make file.touch work on directories and fix some tests when using `--no-clean`
2012-08-06 01:03:49 -07:00
Thomas S Hatch
0d195949d6 Merge pull request #1768 from s0undt3ch/cleanup-parsers
Parsers(master, minion, syndic) cleanup code.
2012-08-06 00:58:49 -07:00
Paul Collins
f1965e2c01 Fix log option in pip module 2012-08-05 19:52:35 -07:00
Thomas S Hatch
bda1dec33a Fix log message in py renderer 2012-08-05 20:00:04 -06:00
Scott Walton
d7bd6589e7 Removed TODO after reading source 2012-08-05 22:17:54 +01:00
Pedro Algarvio
b8135aa801 Fix bug when calling salt-call --doc without args. Should output all documentation. 2012-08-05 19:51:48 +01:00
Pedro Algarvio
c89928ec33 Typo. 2012-08-05 19:31:13 +01:00
Pedro Algarvio
a4b96eacfc Corrected last commit line placement. 2012-08-05 19:29:56 +01:00
Pedro Algarvio
dcc0efcd70 Re-add wrongly removed line. 2012-08-05 19:27:28 +01:00
Pedro Algarvio
d01b8da9aa Fix some tests when using --no-clean
When using `--no-clean` while running tests, some files/dirs still need to be removed, if not, test will fail. This commit tries to addresses those issues.
2012-08-05 19:23:12 +01:00
Pedro Algarvio
59add96a95 Include a missing .format() call to a message. 2012-08-05 18:53:25 +01:00
Pedro Algarvio
6b1bfb6eb7 Make file.touch also work with directories.
Instead of relying that what we're touching is a file, first check if the provided path exists, if not, create a file, else, just update times.
2012-08-05 18:50:11 +01:00
Pedro Algarvio
3f1aa40877 Improved the salt loader names for log filtering.
Now, when running the salt loader, we get dotted names for the loaded modules, states, etc.
Instead of, for example `foo_module`, `bar_state`, we now get `salt.loaded.module.foo` and `salt.loaded.state.bar`, etc.
This will greatly help using the granular log filtering.
2012-08-05 18:41:43 +01:00
Thomas S Hatch
896a816119 Merge pull request #1769 from amuraru/develop
Fixed sync and reload of custom modules bundled in packages
2012-08-04 19:56:03 -07:00
Adrian Muraru
4b18e4ca41 Fixed sync and reload of custom modules bundled in packages 2012-08-05 02:01:55 +03:00
Pedro Algarvio
9d1a252136 Fix some left over code. 2012-08-04 23:46:28 +01:00
Thomas S Hatch
12010e054f Clean up conflicing pillar data in the docs 2012-08-04 16:42:21 -06:00
Scott Walton
a724427e73 Fixed coding error #1766 2012-08-04 23:26:05 +01:00
Pedro Algarvio
ac1ee79fa6 Cleanup the salt-run(salt.cli.SaltRun) binary parser.
Reused the timeout mix-in. All cli tools parsers also reuse the config mixin.
This commit finishes cleaning up the cli tool parsers.
2012-08-04 23:25:37 +01:00
Pedro Algarvio
261450e90f Cleanup the salt-call(salt.cli.SaltCall) binary parser.
Reused the logging and output mix-ins.
2012-08-04 23:07:39 +01:00
Pedro Algarvio
060f33a15a Cleanup the salt-key(salt.cli.SaltKey) binary parser.
Reused the output options and logging setup mix-ins.

Fixed a bug introduced in previous commit on `salt.utils.parsers.SaltCPOptionParser._mixin_after_parsed()`, function does not accept any arguments.
2012-08-04 22:55:15 +01:00
Pedro Algarvio
f5aad4f8e2 Cleanup the salt-cp(salt.cli.SaltCP) binary parser.
For this, the timeout mix-in and both the target and output parser group mix-ins were re-used. Way less code and logic to keep track of.
Added a simple test for this binary too.
2012-08-04 22:28:51 +01:00
Scott Walton
865414bf28 Modified user_exists to query the database; partial fix for #1766 2012-08-04 22:16:34 +01:00
Pedro Algarvio
b582e40ff1 Cleanup the salt(salt.cli.SaltCMD) binary parser.
* Created 2 mix-ins as option groups, the output options and the target options. This will allow adding some explanatory text besides separating these options from the parser's main options.
* All options on the parser, including the grouped options are now merged to the loaded configuration which will latter get passed on.
* Also created the timeout mix-in which will be used in other binaries.
2012-08-04 22:08:06 +01:00
Pedro Algarvio
503f4bdf08 Remove extra kwargs to setup_config. 2012-08-04 20:31:59 +01:00
Pedro Algarvio
d776705e49 Parsers(master, minion, syndic) cleanup code.
Moved the minion, master and syndic parsers to use mixins to clean up, reuse, and automate some of the required procedures.
2012-08-04 19:58:32 +01:00
Thomas S Hatch
19a93709b1 Add soem checks to compile_highstate 2012-08-04 10:52:15 -06:00
Thomas S Hatch
da9f182dec Return errors when they show up in show_lowstate 2012-08-04 10:46:12 -06:00
Thomas S Hatch
5f3552862b Merge pull request #1763 from rhyselsmore/develop
Debian Service Module now supports reloads
2012-08-03 00:29:15 -07:00
Rhys Elsmore
eac5c79e0f Debian Service now supports reloads 2012-08-03 17:26:43 +10:00
Thomas S Hatch
4ada676894 Merge pull request #1761 from herlo/master
More documentation cleanup
2012-08-02 23:47:07 -07:00
Thomas S Hatch
1543f1223f there is no 1.0 2012-08-03 00:31:25 -06:00
Clint Savage
9a5d086bf3 more documentation cleanup 2012-08-03 00:23:39 -06:00
Thomas S Hatch
40a318f071 Fix signal doc string, SIGKILL is 9 2012-08-02 23:22:24 -06:00
Thomas S Hatch
730a924452 Merge pull request #1759 from herlo/master
Reworded paragraphs and fixed up some grammar
2012-08-02 22:04:22 -07:00
Thomas S Hatch
ddca1526e9 Merge pull request #1760 from archtaku/subnetdata
Add subnet data to network module
2012-08-02 22:02:54 -07:00
Erik Johnson
ccab296fa7 Add subnet data
Introduces two new module functions: network.subnets and
network.in_subnet. The former returns a list of subnets to which the
minion belongs, and the latter returns True/False depending on whether
or not the minion belongs to a given subnet. Note that the argument to
netork.in_subnet need not be a subnet from the list provided by
network.subnets.
2012-08-02 23:32:58 -05:00
Clint Savage
015766d28b reworded paragraphs and fixed up some grammar 2012-08-02 22:04:37 -06:00