2011-02-14 10:16:50 +00:00
|
|
|
cat << eof
|
|
|
|
|
2010-12-01 19:06:07 +00:00
|
|
|
Hey hackers,
|
|
|
|
|
|
|
|
cdist has not been published, you're accessing a early in developent
|
|
|
|
code.
|
|
|
|
|
|
|
|
Do not believe anything written in cdist, besides what's written in this file
|
|
|
|
(everything else may be future stuff for the initial release).
|
|
|
|
|
|
|
|
-- Nico, 20101201
|
|
|
|
|
|
|
|
|
2011-02-03 12:24:56 +00:00
|
|
|
What you can do so far: (executed from top level directory)
|
2010-12-01 19:06:07 +00:00
|
|
|
|
2011-02-17 15:13:35 +00:00
|
|
|
The following code will get executed if you run this README,
|
|
|
|
I usually do it like this:
|
|
|
|
|
|
|
|
% rm -rf /tmp/localhost && ./HACKERS_README
|
2011-02-14 10:16:50 +00:00
|
|
|
|
|
|
|
eof
|
|
|
|
|
2011-02-16 18:45:33 +00:00
|
|
|
# Tell the user what we do, so this script makes sense during execution
|
2011-02-17 15:26:48 +00:00
|
|
|
set -x
|
|
|
|
|
|
|
|
# Abort on any error
|
|
|
|
set -e
|
2011-02-16 18:45:33 +00:00
|
|
|
|
2011-02-17 08:16:44 +00:00
|
|
|
# prepare use (only from top level directory)
|
2010-12-01 19:06:07 +00:00
|
|
|
export PATH="$PATH:$(pwd -P)/bin"
|
2011-02-17 08:16:44 +00:00
|
|
|
export __cdist_config="$(pwd -P)/conf"
|
|
|
|
|
2011-02-17 15:42:59 +00:00
|
|
|
__cdist_out_objects=/tmp/localhost/objects
|
|
|
|
__cdist_out_explorers=/tmp/localhost/explorers
|
|
|
|
__cdist_out_execs=/tmp/localhost/exec
|
2010-12-01 19:06:07 +00:00
|
|
|
|
2011-02-17 08:16:44 +00:00
|
|
|
|
2011-02-17 15:33:16 +00:00
|
|
|
# Run explorer on a "remote" host
|
2011-02-17 15:42:59 +00:00
|
|
|
cdist-explorer-run localhost "$__cdist_out_explorers"
|
2011-02-17 15:33:16 +00:00
|
|
|
|
|
|
|
# Display result
|
2011-02-17 15:42:59 +00:00
|
|
|
find "$__cdist_out_explorers"
|
2011-02-17 15:33:16 +00:00
|
|
|
|
2011-02-02 20:49:01 +00:00
|
|
|
# Test first level manifest execution
|
2011-02-17 15:42:59 +00:00
|
|
|
cdist-manifest-init localhost "$__cdist_out_objects"
|
2011-02-02 20:49:01 +00:00
|
|
|
|
|
|
|
# See what it generated
|
2011-02-17 15:42:59 +00:00
|
|
|
find "$__cdist_out_objects"
|
2011-02-04 21:51:16 +00:00
|
|
|
|
2011-02-16 22:08:33 +00:00
|
|
|
# Generate all objects, including from types that generate objects as well
|
2011-02-17 15:42:59 +00:00
|
|
|
cdist-manifest-run-all localhost "$__cdist_out_objects"
|
2011-02-16 22:08:33 +00:00
|
|
|
|
|
|
|
# See what it generated
|
2011-02-17 15:42:59 +00:00
|
|
|
find "$__cdist_out_objects"
|
2011-02-16 22:08:33 +00:00
|
|
|
|
2011-02-16 19:24:58 +00:00
|
|
|
# Generate code for all objects in object dir
|
2011-02-17 15:42:59 +00:00
|
|
|
cdist-object-codegen-all localhost "$__cdist_out_objects" "$__cdist_out_execs"
|
2011-02-16 19:24:58 +00:00
|
|
|
|
2011-02-17 14:35:56 +00:00
|
|
|
# Display result, including permissions
|
2011-02-17 15:42:59 +00:00
|
|
|
ls -lR "$__cdist_out_execs"
|
2011-02-17 14:11:41 +00:00
|
|
|
|
|
|
|
# Transfer generated code
|
2011-02-17 15:42:59 +00:00
|
|
|
cdist-exec-transfer localhost "$__cdist_out_execs"
|
2011-02-17 14:35:56 +00:00
|
|
|
|
|
|
|
# Execute generated code
|
|
|
|
cdist-exec-run localhost
|