Merge branch 'master' into preos

This commit is contained in:
Nico Schottelius 2014-06-13 13:33:28 +02:00
commit 3b4258c34e
131 changed files with 1636 additions and 272 deletions

View file

@ -4,4 +4,14 @@
implemented as a proof of concept at:
https://github.com/asteven/cdist/tree/type-namespaces
Execute all global explorers only when needed #286
My intention is to create a brunch of global explorer which are of use in some cases and makes cdist more userfriendly. But now, all global explorers are allways executed, even the return value of the explorers is never used.
I think a possible approach can be to replace the result files with pipes, and on first read of the pipe, the explorer is executed by the core, all following read calls from the pipe are answered from the core with the result of the first real execute of the explorer.
So cdist can have an unlimited number of global explorers and only used explorers are executed on the target host, all other explorers laying around are simply ignored.
Also a possible approach would be to create a new explorer type (dynamic explorers) which are sitting in a different directory to (for example dynexploer) and only this ones are executed with the conditional approach explained above. So the overhead to create pipes and monitor it is only in place on explorers which are not interesting for everyone ...

View file

@ -0,0 +1,27 @@
Problem shown by using __rbenv:
__rbenv/nicotest
__git /home/nico/.rbenv
__package git
__directory /home/nico/.rbenv
require="__git/home/nico/.rbenv"
__git /home/nico/.rbenv/plugins/ruby-build
__package git
__directory /home/nico/.rbenv/plugins/ruby-build
1) if children do NOT automatically depend on their parents requiremnts
__directory /home/nico/.rbenv/plugins/ruby-build fails:
because __directory /home/nico/.rbenv/plugins is created by
__git /home/nico/.rbenv, but __directory /home/nico/.rbenv/plugins/ruby-build
does not depend on __git /home/nico/.rbenv
2) if children DO automatically depend on their parents requiremnts
__package git from __git /home/nico/.rbenv/plugins/ruby-build depends on __git /home/nico/.rbenv.
__git /home/nico/.rbenv depends on __package git (via autorequire)
=> circular dependency, they depend on each other

View file

@ -0,0 +1,86 @@
With Steven
t marker .cdist breaks
- use random marker that starts with .cdist-
- has fixed number of following characters (like 6 or 10)
- write marker name to $__global/marker
- export $__global/marker path as $__marker
- document variable in cdist-reference
- also document the pattern how the marker is built
so that other people may be able to dig into the structure
from outside
t save method
- in $__global/method
- values
- config
- install
- document path and description in cdist-reference
t save whole runtime in cache
- missing items
- initial manifest may be specified on commandline
- always save the initial manifest to $__global/initial-manifest
- currently it is a lost tempfile
- remote exec / remote copy
- save to $__global/remote_exec
- save to $__global/remote_copy
- stdout and stderr of everything
- need to implement Steven's patch of stderr/stdout capturing
- exit code of cdist
- if it is complete, we can use it for replay / reconfigure
- new idea: replay / reconfig / reinstall
- --from-cache?
t stderr/stdout
- capture all messages
- prefix with target_host
- implementation exists in one of Steven's branches
- ping steven for updated pull request
x on error dump all information about the failing object
- where created
- stderr
- stdout
- parameter (+values)
- everything known [tm]
t multiple versions of cache
- see #298
t absolute path of types, explorer
- resolve instead of using the temporary link name
- #305
t report command
- from cache?
- #306
t add session to "run directories"
- instead of /var/lib/cdist (remote)
- instead of static dir in cache
- same id remote and local
- maybe timestamp
- in or excluding the pid of cdist?
- cache
- also save when cdist fails
- save exit code
- be able to restore config
- new command: cdist clean-cache
- --since
- --keep-versions --keep-lala $num
- cdist 4.0.0pre2
- cleanup in preos
- logging for types
cdist log ...?
- cdist logserver
- $__global/log.socket
- fifo?
echo into logpipe?

View file

@ -0,0 +1,18 @@
- we cannot install packages, which are not authenticated:
INFO: voicerepublic-staging.sky.ungleich.ch: Executing code for __package_apt/deb-multimedia-keyring
Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
deb-multimedia-keyring
0 upgraded, 1 newly installed, 0 to remove and 13 not upgraded.
Need to get 14.4 kB of archives.
After this operation, 46.1 kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
deb-multimedia-keyring
E: There are problems and -y was used without --force-yes
ERROR: voicerepublic-staging.sky.ungleich.ch: Command failed: ssh -o User=root -q voicerepublic-staging.sky.ungleich.ch /bin/sh -e /var/lib/cdist/object/__package_apt/deb-multimedia-keyring/.cdist/code-remote
INFO: cdist: Total processing time for 1 host(s): 72.07943892478943
ERROR: cdist: Failed to configure the following hosts: voicerepublic-staging.sky.ungleich.ch