Commit Graph

45138 Commits

Author SHA1 Message Date
Erik Johnson
89413ac7ba Fixup indentation 2015-02-10 15:06:45 -06:00
Erik Johnson
c4fc5f5fa4 More info for LXC tutorial 2015-02-10 15:06:45 -06:00
Erik Johnson
424de6a1a6 Add back lxc.started state for compatibility 2015-02-10 15:06:45 -06:00
Erik Johnson
2dad71adc9 Add more info to LXC tutorial 2015-02-10 15:06:45 -06:00
Erik Johnson
f98fe0b312 Add lxc.templates function 2015-02-10 15:06:45 -06:00
Erik Johnson
51d2710fc8 Docstring and logging fixes 2015-02-10 15:06:45 -06:00
Erik Johnson
7ee9ea323a Clarify docstring 2015-02-10 15:06:45 -06:00
Erik Johnson
14ac9f1153 More bootstrap fixes
Also, don't raise exceptions when lxc.init fails, just report the errors
and let the init continue if possible.
2015-02-10 15:06:45 -06:00
Erik Johnson
0067f59963 Update docstring/comments 2015-02-10 15:06:45 -06:00
Erik Johnson
a9261065a1 Fix lxc.bootstrap
I inadvertently broke this when resolving the merge conflict as I was
rebasing, since the location where the retrieved bootstrap script was
modified between 2014.7 and develop.
2015-02-10 15:06:45 -06:00
Erik Johnson
309a6715d1 Fixes after rebasing against develop 2015-02-10 15:06:44 -06:00
Erik Johnson
62e25fc016 Bugfixes from LXC refactor
Also reclassify the new functionality as being added for the Lithium
release
2015-02-10 15:06:44 -06:00
Erik Johnson
7029bd978b Add back "orig" param for lxc.clone
Also move bootstrap_delay to lxc.bootstrap
2015-02-10 15:06:44 -06:00
Erik Johnson
9cec83ac3b Remove unsupported argument 2015-02-10 15:06:44 -06:00
Erik Johnson
8fffa88a95 Deprecate "orig" parameter in favor of "clone_from" 2015-02-10 15:06:44 -06:00
Erik Johnson
38d64fc95b LXC state fixes
These are things that needed to be fixed/adjusted as a result of issues
found in manual testing.
2015-02-10 15:06:44 -06:00
Erik Johnson
5d70029a40 Don't use _marker for default kwarg match in create()
The kwargs are passed in as None by the lxc.present state if no value
was specified, so ignore the kwarg match and go for the profile match
unless a kwarg has a non-None value.
2015-02-10 15:06:44 -06:00
Erik Johnson
f777edfbec Unfreeze frozen container before stopping
Gracefully stopping a frozen container results in a significant delay,
at least in my testing. This commit unfreezes the container before
stopping it, if the container was frozen when the stop() function is
called.
2015-02-10 15:06:44 -06:00
Erik Johnson
e019e5a474 Finish LXC state refactoring 2015-02-10 15:06:44 -06:00
Erik Johnson
072b39cc76 Always show prior state even state didn't change
Also some further refactoring of the maintenance functions, including
adding a "restart" function and deprecating the "restart" argument in
lxc.start.
2015-02-10 15:06:44 -06:00
Erik Johnson
048d3f31ff Merge lxc.cloned into lxc.created state, rename to lxc.present
Also remove another redundant state which can be run using module.run.
2015-02-10 15:06:44 -06:00
Erik Johnson
8165aeeae4 Remove snapshot from clone args
Let it live in kwargs so that it can be part of a profile
2015-02-10 15:06:44 -06:00
Erik Johnson
30c3a7f0fb Fix creation of container from image
Also changed return data for create() to match destroy(), clone(), etc.
2015-02-10 15:06:44 -06:00
Erik Johnson
b06bd4f8df Add self.strerror to SaltException class
This helps avoid deprecation warnings that happen when self.message is
referenced.
2015-02-10 15:06:43 -06:00
Erik Johnson
e297fd4102 Complete LXC refactor 2015-02-10 15:06:43 -06:00
Erik Johnson
728488e90b Tweak section header 2015-02-10 15:06:43 -06:00
Erik Johnson
4134af175e Further work on lxc refactor
Most functions are now refactored. Also added functions to match the
ones in cmdmod.py so that running commands within containers more
closely resembles running commands on minions themselves.
2015-02-10 15:06:43 -06:00
Erik Johnson
86f9dfa8e5 Modify lxc.created state, remove lxc.set_pass state
This commit modifies the lxc.created state to catch exceptions raised by
the lxc execution module. Additional states will follow.

If passwords need to be set, they can be done with a module.run state.
This function is not stateful and thus would run every time, making it a
bad fit as a state.
2015-02-10 15:06:43 -06:00
Erik Johnson
196a7d6327 Stub for LXC tutorial 2015-02-10 15:06:43 -06:00
Erik Johnson
8e958494c1 Add missing gather_bootstrap_script function
This is required by lxc.bootsrap but was only present in the develop
branch.
2015-02-10 15:06:43 -06:00
Erik Johnson
c79d867db2 Add stdin and output_loglevel args to cmd.run_chroot
Also allow the cmd function to be overridden with a __context__
variable.
2015-02-10 15:06:43 -06:00
Erik Johnson
d1b5e630da Correct incorrect info in docstring 2015-02-10 15:06:43 -06:00
Erik Johnson
59d1754844 Make arguments vertical for easier reading 2015-02-10 15:06:43 -06:00
Erik Johnson
aaaf2d64b5 Lint fixes + fix bad config entry name 2015-02-10 15:06:43 -06:00
Erik Johnson
e20044026a LXC re-factor (WIP) 2015-02-10 15:06:43 -06:00
Erik Johnson
49d95ec08c Allow interface dict to be passed to salt.utils.network.ip_addrs{,6}
This will allow the lxc.info function leverage existing logic rather
than trying to parse ip/ifconfig output by itself.
2015-02-10 15:06:43 -06:00
Erik Johnson
b4cf28c2c6 Properly set lxc.utsname and /etc/hostname 2015-02-10 15:06:43 -06:00
Thomas S Hatch
8734d6f8cc Merge pull request #20554 from Unity-Technologies/unzip-symlink
Fixed the extraction of symbolic links from zip archives
2015-02-10 10:18:14 -07:00
Thomas S Hatch
630d03b4b3 Merge pull request #20447 from jacksontj/2015.2
2015.2: backport overhaul of LazyLoader from #20274
2015-02-10 09:46:53 -07:00
Erik Johnson
85a689ed63 Merge pull request #20550 from kim0/freebsd-pkg-upgrade-single-pkg
Add support for upgrading named packages on FreeBSD pkgng
2015-02-10 10:38:34 -06:00
Daniel Hobley
e3e9f20510 Pylint 2015-02-10 17:04:57 +01:00
Daniel Hobley
f893029b84 Fixed the extraction of symbolic links from zip archives 2015-02-10 16:26:39 +01:00
Ahmed Kamal
dfeaa19b0e Linter happiness 2015-02-10 04:54:17 +02:00
Ahmed Kamal
aa5ae496e0 Add support for upgrading named packages on FreeBSD pkgng 2015-02-10 04:38:20 +02:00
Nicole Thomas
3e2e9e3861 Merge pull request #20532 from rallytime/bp-20501
Backport #20501 to 2015.2
2015-02-09 17:10:30 -07:00
Nicole Thomas
525f00cb44 Merge pull request #20529 from basepi/merge-forward-2015.2
Merge forward from 2014.7 to 2015.2
2015-02-09 17:09:57 -07:00
Daniel Wallace
7d70cd19c4 add note about rackconnectv3 variable 2015-02-09 16:12:33 -07:00
Daniel Wallace
bbab6235e0 fix rackconnect v3 implementation 2015-02-09 16:12:33 -07:00
Colton Myers
eba17606b4 Merge remote-tracking branch 'upstream/2014.7' into merge-forward-2015.2 2015-02-09 15:37:25 -07:00
jfindlay
9246f64f9b Merge pull request #20523 from terminalmage/fix-kwarg-parsing
Fix regression in arg parsing
2015-02-09 12:55:22 -07:00