Commit graph

659 commits

Author SHA1 Message Date
Nico Schottelius
13d47f3cf4 remove datetime from config to wrong position
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 20:20:35 +02:00
Nico Schottelius
609efcbfd1 Remove datetime from config_install, break code and make it more beautiful
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 20:14:34 +02:00
Nico Schottelius
1db4cd48d2 -typo
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 20:11:23 +02:00
Nico Schottelius
14082f5c00 string, not tuple in exception
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 20:05:24 +02:00
Nico Schottelius
a87e6f22b5 use new cdist.Error exception
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:59:07 +02:00
Nico Schottelius
d07a191867 add logger to config
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:54:41 +02:00
Nico Schottelius
ae9eba80a9 use require, not __require in emulator
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:50:45 +02:00
Nico Schottelius
ccb2ffcae6 remove toplevel object/type
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:47:55 +02:00
Nico Schottelius
8305f07aab stage prepare uses new object interface
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:43:07 +02:00
Nico Schottelius
344bfb0603 was the object prepared/ran?
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:40:19 +02:00
Nico Schottelius
5c9694215c setup '__cdist_out_dir' in path for use in Object
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:26:58 +02:00
Nico Schottelius
2157cef2a6 make cdist.MissingEnvironmentVariableError print the key and not fail :-)
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 19:22:08 +02:00
Nico Schottelius
df5de24b72 begin use of cdist.core.Object.list_objects()
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 18:26:55 +02:00
Steven Armstrong
c0854ebb2e remove unused constant
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 17:47:08 +02:00
Nico Schottelius
bfba1938ca Merge remote-tracking branch 'steven/oo-restructure' 2011-10-06 17:37:14 +02:00
Steven Armstrong
3a1cea6887 file system backed properties
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 17:16:12 +02:00
Steven Armstrong
12dc0d2bdd cleanup and file system backed properties
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 17:15:45 +02:00
Nico Schottelius
1da7436fcb Merge branch 'install'
Conflicts:
	lib/cdist/config.py

Some problems left.

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 17:06:56 +02:00
Nico Schottelius
60b5f8783c revert changes from upcoming install branch
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 17:02:37 +02:00
Nico Schottelius
50edf2863a Merge remote-tracking branch 'steven/oo-restructure' 2011-10-06 17:00:52 +02:00
Nico Schottelius
220611604b +:
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 17:00:09 +02:00
Nico Schottelius
efe8dbfa85 Merge remote-tracking branch 'steven/oo-restructure'
Conflicts:
	lib/cdist/config.py
	lib/cdist/path.py

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 16:57:48 +02:00
Nico Schottelius
1c8a143397 commit previously missed change
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 16:52:56 +02:00
Nico Schottelius
54fb9e6c3f Merge branch 'master' into install
Conflicts:
	lib/cdist/config.py
	lib/cdist/path.py

Merged changes from config.py to config_install.py

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 16:52:20 +02:00
Nico Schottelius
8b561fd63c fixup correct split/insert of os.environ() for target_host and args
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 16:30:06 +02:00
Nico Schottelius
26278b1e32 expose target host from config
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 16:28:21 +02:00
Nico Schottelius
919f67184a do not reference scp anymore
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 15:49:08 +02:00
Nico Schottelius
5a7e4b2f32 quiet ssh/scp
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 15:48:44 +02:00
Steven Armstrong
0d9906b0b8 --typo, missing colon
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 15:18:06 +02:00
Nico Schottelius
59bee14101 begin to eliminate remote_user/prefix from path
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 14:02:37 +02:00
Nico Schottelius
df630e1fdf user remote_prefix=True now
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 13:40:46 +02:00
Nico Schottelius
eea6a38f33 cat only locally :-)
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 13:39:08 +02:00
Nico Schottelius
278c379e07 use os.environ['__remote_exec'] in exec*
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 13:37:12 +02:00
Nico Schottelius
ecc4fc10d7 setup __remote_exec and __remote_copy variables
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 13:34:45 +02:00
Steven Armstrong
a15972f20d +docstring
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 13:21:48 +02:00
Steven Armstrong
41ab7390db use constant instead of string for .cdist
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 13:02:08 +02:00
Steven Armstrong
4de5f6f58e move Type into its own file
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 13:00:17 +02:00
Steven Armstrong
080ca10e19 new package cdist.core
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 12:58:08 +02:00
Steven Armstrong
cdba503ff2 move Object class into its own file
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 12:57:38 +02:00
Steven Armstrong
a4abb53ced +MissingEnvironmentVariableError
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-06 12:52:13 +02:00
Nico Schottelius
2ec2ab26ce update path with changes from yesterday (system crash)
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 12:34:34 +02:00
Nico Schottelius
820eea56fb install finish
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-06 09:27:16 +02:00
Steven Armstrong
82f548bafd Merge remote-tracking branch 'telmich/install' into oo-restructure 2011-10-05 17:06:56 +02:00
Nico Schottelius
f84cabffe3 cleanup path
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 16:49:20 +02:00
Steven Armstrong
94d926c0d6 Merge remote-tracking branch 'telmich/install' into oo-restructure 2011-10-05 16:48:15 +02:00
Steven Armstrong
8e06626c5a Merge remote-tracking branch 'telmich/install' into oo-restructure 2011-10-05 16:47:49 +02:00
Nico Schottelius
7f85aab3ef add some pseudo code to adapt to changes
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 16:45:10 +02:00
Steven Armstrong
2e61e8b202 finish object class
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-05 16:44:22 +02:00
Nico Schottelius
a0c984acdd config+install is broken now due to refactoring
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 16:38:19 +02:00
Nico Schottelius
68889c4bf7 finish type, shrink path
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 16:12:25 +02:00
Steven Armstrong
099adec61f start working on object class
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
2011-10-05 16:08:29 +02:00
Nico Schottelius
2176e4e2d4 begin new type type (no typo)
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 16:05:11 +02:00
Nico Schottelius
28428177ae --typo
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 15:53:34 +02:00
Nico Schottelius
9128cc28c4 introduce a lot todo in path
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 15:50:17 +02:00
Nico Schottelius
a875d69d7e continue on test_path testcase
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-05 14:15:05 +02:00
Nico Schottelius
b3f914f6f6 create base module for install and config
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 18:45:29 +02:00
Nico Schottelius
f88cb78d61 finish test_path.test_type_detection
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 18:36:43 +02:00
Nico Schottelius
8dd248cf76 cleanup on exit and begin to create test types
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 17:01:11 +02:00
Nico Schottelius
6c22867fc2 begin to test path and add method to check type
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 16:32:43 +02:00
Nico Schottelius
40a1619c1a make build test work (or fail, but work) again
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 16:15:10 +02:00
Nico Schottelius
3d75ec9bfc make test suite usable from command line
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 15:49:18 +02:00
Nico Schottelius
410a2fe7ff test_explorer_ran finished
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 15:08:37 +02:00
Nico Schottelius
13ed37a4e9 begin to test explorer success in test_install
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 14:45:35 +02:00
Nico Schottelius
db322c0b5e integrate tests into library
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-10-04 14:29:33 +02:00
Nico Schottelius
26c0d5d9aa upcoming changes for 2.0.3
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 17:27:28 +02:00
Nico Schottelius
d15d659248 increment version for next release
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 17:20:43 +02:00
Nico Schottelius
d8da7635de use warning loglevel by default
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 17:15:54 +02:00
Nico Schottelius
b52939ccfe only debug if __debug is setup
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 16:40:50 +02:00
Nico Schottelius
ae7887f775 ++changes
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 16:25:58 +02:00
Nico Schottelius
a165585699 pass __debug to manifest
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 16:20:46 +02:00
Nico Schottelius
272b8722c1 fix output, compare string with string not string with list
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 16:10:53 +02:00
Nico Schottelius
ccbd0f1d84 introduce config.link_emulator() to be called from test
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 16:05:26 +02:00
Nico Schottelius
cc87573d6b remove lecagy cdist-type-emulator support
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 15:35:04 +02:00
Nico Schottelius
0913bb21dd use raise instead of sys.exit in emulator
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 14:08:11 +02:00
Nico Schottelius
9d582ae24f rename emulator to run
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 14:01:09 +02:00
Nico Schottelius
6f1a13b531 move emulator link to emulator module and make source variable (exec_path)
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 13:38:25 +02:00
Nico Schottelius
2c0a7adf74 replace CdistError with cdist.Error
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 00:49:12 +02:00
Nico Schottelius
df84480fcc BUGFIX: emulator compared parameter with value
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-27 00:02:04 +02:00
Nico Schottelius
c687dbdc70 remove remote_cat, as it's only used in exec module
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 16:22:09 +02:00
Nico Schottelius
6e73572a95 easier check for remote_prefix
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 16:21:56 +02:00
Nico Schottelius
7882b4a3ac only print env, if existent
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 16:03:53 +02:00
Nico Schottelius
4906f604f0 raise cdist errors
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 15:42:39 +02:00
Nico Schottelius
fc1e0d9f1f remove exec bits from copying
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:55:59 +02:00
Nico Schottelius
27b4b9cd03 also move out install and cleanup library path code
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:53:09 +02:00
Nico Schottelius
35e33570d1 also move out config
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:45:19 +02:00
Nico Schottelius
0197f8da13 more cleanups from refactoring
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:25:22 +02:00
Nico Schottelius
74dc5b96cb type emulator begins to run
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:21:04 +02:00
Nico Schottelius
6d75016139 make type emulator load again
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:18:36 +02:00
Nico Schottelius
3f6c479d72 move TYPE_PREFIX back into main, as it's only needed there and should work without module
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:07:45 +02:00
Nico Schottelius
16d58dcac7 move out banner, fail at emulator
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 11:05:18 +02:00
Nico Schottelius
e6a903fd96 cleanup logger stuff, remove more path stuff from cdist bin
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 10:28:57 +02:00
Nico Schottelius
8f2e5bb8c8 cleanup and move error class to init
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 10:25:51 +02:00
Nico Schottelius
bc9bc37aab use remote_prefix internally
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-26 10:17:02 +02:00
Nico Schottelius
8af45f83b2 rearange remote_user
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 20:53:09 +02:00
Nico Schottelius
3925ba1c6e pass remote_prefix to run_or_fail/shell
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 20:35:13 +02:00
Nico Schottelius
e14848ec1f remove run* from cdist and put it into lib/exec
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 20:21:10 +02:00
Nico Schottelius
79173488ff cdist runs with path module loaded (unusued though)
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 20:08:55 +02:00
Nico Schottelius
26fad6f23c correct base dir, now relative to lib
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 19:13:36 +02:00
Nico Schottelius
6139fab354 import cdist.path works
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 19:10:07 +02:00
Nico Schottelius
8e59f97800 begin to used cdist.path
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-23 18:55:23 +02:00
Nico Schottelius
4e8f99b01d almost completly implemented type emulator in python
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-19 00:36:35 +02:00
Nico Schottelius
d6db6d0c7e begin move of cdist-type-emulator to lib/ and submit initial_manifest to cdist
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-09-08 15:20:25 +02:00
Nico Schottelius
e5297ddf31 move types to config dir
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-02-02 21:36:03 +01:00
Nico Schottelius
33d05d3519 add dummy manifest for type: file
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-01-19 08:56:18 +01:00
Nico Schottelius
9130ee71f4 this is not a manifest, but gencode part
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-01-19 08:54:37 +01:00
Nico Schottelius
4d4a13b0ab add functionality to type "file"
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-01-18 21:21:30 +01:00
Nico Schottelius
b81b19d126 begin to create first type: file
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2011-01-18 21:17:20 +01:00
Nico Schottelius
49ab674edf move lib below conf
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2010-09-19 14:04:39 +02:00
Nico Schottelius
847054c77d finish cdist-explore
Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
2010-09-19 13:52:00 +02:00