cScm Configuration Daemon

cScm – is a tool to convert SCM configuration files into binary format and store its in shared memory for reading by cSvn-ui and cGit-ui CGI scripts

12 Commits   0 Branches   1 Tag
     5         kx 
     5         kx # [cScm Daemon](https://csvn.radix.pro/cscm/trunk/doc/cscmd.8.md)
     5         kx 
     5         kx **cscmd** – a daemon for monitoring changes in SCM configuration files.
     5         kx 
     5         kx 
     5         kx ## Table of Contents
     5         kx 
     5         kx * [Options](#options)
     5         kx * [Grammar](#grammar)
     5         kx * [See Also](#see-also)
     5         kx 
     5         kx <br/>
     5         kx 
     5         kx In order to not load the **cSvn-ui** and **cGit-ui** CGI scripts with unnecessary functionality and speed up
     5         kx its work, information about the list of repositories is transmitted to it in binary form through
     5         kx shared memory (see: */dev/shm/csvn.bcf*, */dev/shm/cgit.bcf*).
     5         kx 
     5         kx Binary Config File (**BCF**) format is similar to the simplified implementation of the **COFF**
     5         kx and is described in the header file [*/usr/include/cscm/bcf.h*](https://csvn.radix.pro/cscm/trunk/cscm/bcf.h).
     5         kx 
     5         kx On startup, the daemon parses the */etc/csvn-ui.rc* or */etc/csvn-ui.rc* configuration files
     5         kx (depends on **--scm=[svn|git]** option) and stores its binary forms in shared memory. In addition, the binary
     5         kx form is saved in the daemon's home directory, by default it is the file */var/lib/csvn/csvn.bcf* or
     5         kx */var/lib/cgit/cgit.bcf*.
     5         kx 
     5         kx **cscmd(8)** daemon rereads SCM configuration files upon arrival of the **-HUP** signal and, in addition,
     5         kx can be configured to monitor changes in the configuration files using the `--inotify` option. If the `--inotify`
     5         kx option is specified, then after editing the file */ets/csvn-ui.rc* or */ets/cgit-ui.rc* and saving it to disk,
     5         kx the **cscmd** daemon will reread file */etc/csvn-ui.rc* or */etc/cgit-ui.rc* as if it received the **-HUP** signal.
     5         kx 
     5         kx The work of the **cscmd(8)** daemon's can be monitored by the log, which it leaves in the file
     5         kx */var/log/csvnd.log* or the file */var/log/cgitd.log* (depends on **--scm=[svn|git]** option). There you can also
     5         kx observe messages about errors that are detected in */ets/csvn-ui.rc* or */ets/cgit-ui.rc* files, if any.
     5         kx 
     5         kx To start the **cScm** daemon during system boot, can be used the start/stop script */etc/rc.d/rc.csvnd* or
     5         kx */etc/rc.d/rc.cgitd*.
     5         kx 
     5         kx 
     5         kx ## Options
     5         kx 
     5         kx 
     5         kx ### -h, --help
     5         kx 
     5         kx Display help information.
     5         kx 
     5         kx 
     5         kx ### -v, --version
     5         kx 
     5         kx Display the version of **cScm** daemon.
     5         kx 
     5         kx 
     5         kx ### -d, --daemonize
     5         kx 
     5         kx Run in background as a daemon.
     5         kx 
     5         kx 
     5         kx ### -i, --inotify
     5         kx 
     5         kx Notify about configuration changes. If this option is set then **cscmd(8)** daemon selects changes
     5         kx made in */etc/csvn-ui.rc* or */etc/cgit-ui.rc* configuration file and reread configuration when changes
     5         kx is done. Without this option rereading configuration file can be done by sending **-HUP** to the **cscmd(8)**
     5         kx process.
     5         kx 
     5         kx 
     5         kx ### -b, --bcf=<BCF_FILE>
     5         kx 
     5         kx Binary config file (depends on **--scm=[svn|git]** option). Default: */var/lib/csvn/csvn.bcf*.
     5         kx 
     5         kx 
     5         kx ### -c, --config=<CONFIG_FILE>
     5         kx 
     5         kx Config file (depends on **--scm=[svn|git]** option). Default: */etc/csvn-ui.rc*.
     5         kx 
     5         kx 
     5         kx ### -l, --log=<LOG_FILE>
     5         kx 
     5         kx Log file (depends on **--scm=[svn|git]** option). Default: */var/log/csvnd.log*.
     5         kx 
     5         kx 
     5         kx ### -p, --pid=<PID_FILE>
     5         kx 
     5         kx Log file (depends on **--scm=[svn|git]** option). Default: */var/run/csvnd.pid*.
     5         kx 
     5         kx 
     5         kx ### -s, --scm=[svn|git]
     5         kx 
     5         kx SCM engine name: **svn** or **git**. Default: **svn**.
     5         kx 
     5         kx 
     5         kx ### -t, --test
     5         kx Test the config file and exit.
     5         kx 
     5         kx 
     5         kx ## Grammar
     5         kx 
     5         kx The grammar of the language describing the **cScm** congfiguration is simple
     5         kx ([**parse.y**](https://csvn.radix.pro/cscm/trunk/cscmd/parse.y)). File */etc/csvn-ui.rc*
     5         kx allows you to set variable values and create repository lists as named structures.
     5         kx 
     5         kx Any variables can be defined in the */etc/csvn-ui.rc* file, but only variables with
     5         kx reserved names will be used by the **cSvn** or **cGit** CGI script.
     5         kx 
     5         kx In addition, if a variable already defined at the global level is specified in the
     5         kx description of a repository, then within this repository this variable will have a local
     5         kx value. In other words, within the repository, global variables can be overridden.
     5         kx 
     5         kx 
     5         kx ## See Also
     5         kx 
    10         kx > [**README**](https://csvn.radix.pro/scm-tools/cscm/trunk/README.md)
     5         kx