GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
CDEPLOY(1) FreeBSD General Commands Manual CDEPLOY(1)

cdeploy
deploy a set of configuration files to a target file system

cdeploy [-chnvDSX] [-b backup-dir] [-d destdir] [-u user] [-g group] [-m mode] [-x pattern]

The cdeploy script was written to deploy configuration files (or any other kind of files) from a local directory tree (“source tree”) to another directory tree (“target tree”, by default the root of the file system).

cdeploy sticks to the layout of the source tree. Missing directories in the target tree will be created (if permission is granted to do so); already existing files will be replaced by the version from the source tree. Source files replacing existing target files will be deployed with owner, group and permission of the original target file.

cdeploy creates a backup of the original file before replacing it. These backups are stored as freshly created source tree. In case of trouble with the deployed files, the backup can be restored by simply deploying it like any other source tree.

The following options are available:
backup-dir
Specify a location where the backup will be created. By default, cdeploy uses ~/.cdeploy to store backups.
Only deploy files if the source file differs from the target file. Equity of source and target file are tested by comparing their MD5 fingerprint generated by OpenSSL dgst(1)
Do not invoke cap_mkdb(1) after having deployed a database template file. This is the default behaviour on all systems except FreeBSD.
destdir
Set destdir as root directory for the deployment target. The complete source directory tree will be deployed into the given target directory. cdeploy uses / as default deployment target.
group
Deploy files with group group if automatic detection fails (e. g. if there is not yet a target file to replace)
Print a help message including a short usage summary and exit.
loglevel
Set log level to loglevel. Valid log levels are DEBUG, INFO, WARN and ERROR. This option controls the amount of information dumped to stdout(4). By default, the log level is set to WARN.
mode
Deploy files with mode mode if automatic detection fails (e. g. if there is not yet a target file to replace)
This option suppresses any escape sequences in the output generated by cdeploy. It is particularly useful when working on a terminal which cannot process color escape sequences, or when the output of cdeploy gets redirected to a file.

Please note: This option should be specified as early as possible since before it has been processed, any output will still contain escape sequences.

This flag causes cdeploy to run in simulation mode. In simulation mode, no modifications to the target directory structure will be made. However, cdeploy will test whether all necessary modifications could be made.
user
Deploy files with owner user if automatic detection fails (e. g. if there is not yet a target file to replace)
Print version information and exit.
Ignore the exclusion pattern. By default, cdeploy excludes files and directories originating from common version control systems like CVS, Subversion, Mercurial and Git. This option turns off exclusion completely.
pattern
Exclude all files matching pattern from being deployed. pattern may be a regular expression; extended regular expressions are also supported, as long as they are understood by grep(1). The default exclusion pattern is .svn|.hg|.cvs|.git

The cdeploy utility exits 0 on success, and >0 if an error occurs.

To deploy the content of ~/config, one would use:

cd ~/config
cdeploy

To test which files would be replaced, one would use:

cdeploy -c -S

To skip the creation of backups (which is actually a bad idea), one would set the backup directory to /dev/null:

cdeploy -b /dev/null

Compatibility has been tested with the FreeBSD sh(1) command interpreter (FreeBSD 7 and 8) and the GNU bash(1) (Bourne-Again SHell), version 4.1.5

cap_mkdb(1), grep(1), install(1),

Hopefully none. In case you encounter one, please contact the author.

Jesco Freund <aihal@users.sourceforge.net>
May 1, 2010 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.