-
Notifications
You must be signed in to change notification settings - Fork 67
Getting started with DC
This page assumes that you have successfully
installed cf-sketch and that you are familiar
with some of the core concepts of a CFEngine Sketch. If you
haven't installed cf-sketch
yet, or if you are looking for overview
information, you should read the following pages:
Once you've installed cf-sketch
, follow this simple walkthrough to
run a few commands. The following introduction will get you started,
and give you the quick introduction necessary to start making use of
the Sketches in the CFEngine Design Center.
Note: you can run all these commands as a regular user. In this
case, all the files will be installed under $HOME/.cfagent/
and
cf-sketch will use $HOME/.cf-sketch/
as its configuration directory.
When you run cf-sketch
, you will be presented with an interactive
command prompt from which you can type commands:
# cf-sketch
Welcome to cf-sketch version 2.0.1.
CFEngine AS, 2012.
Enter any command to cf-sketch, use 'help' for help, or 'quit' or '^D' to quit.
cf-sketch>
TODO
cf-sketch
supports an unattended "expert" mode.
Examples of its usage are in the testing Makefile. Use them like this (in this case, we will test the limits sketch):
# cd tools/test
# make limits
Watch an enjoy the fireworks. If you have the pygmentize
utility
and the JavaScript::Beautifier
CPAN module, the output will even be
colored and indented nicely.
You can pass the A=x
parameter to make
to tell it to activate the
sketch only when context x
is defined.
You can pass the T=x
parameter to make
to tell it to set the
test
mode for the sketch only when context x
is defined.
The cf-sketch
expert mode is intended for testing, not for daily
use. You should either use the DC API directly, cf-sketch
interactively, or (in CFEngine Enterprise 3.5 and greater)
the Design Center GUI.
A public repository for customizable CFEngine design patterns and code.