Update documentation.

This commit is contained in:
Mathieu Othacehe 2021-03-22 11:57:46 +01:00
parent 43d29317d9
commit e4a218afb2
No known key found for this signature in database
GPG Key ID: 8354763531769CA6
2 changed files with 105 additions and 28 deletions

12
README
View File

@ -49,20 +49,20 @@ format described [[https://www.postgresql.org/docs/10/libpq-connect.html#LIBPQ-C
By default, this command: By default, this command:
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
./pre-inst-env cuirass ./pre-inst-env cuirass register
#+END_EXAMPLE #+END_EXAMPLE
will connect using the Unix socket at =/var/run/postgresql= to the =cuirass= will connect using the Unix socket at =/var/run/postgresql= to the =cuirass=
database and is equivalent to: database and is equivalent to:
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
./pre-inst-env cuirass --database="dbname=cuirass host=/var/run/postgresql" ./pre-inst-env cuirass register --database="dbname=cuirass host=/var/run/postgresql"
#+END_EXAMPLE #+END_EXAMPLE
To use a TCP connection, one can use: To use a TCP connection, one can use:
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
./pre-inst-env cuirass --database="host=127.0.0.1" ./pre-inst-env cuirass register --database="host=127.0.0.1"
#+END_EXAMPLE #+END_EXAMPLE
* Run tests * Run tests
@ -80,7 +80,7 @@ path before running the usual:
A quick way to manually test Cuirass is to execute: A quick way to manually test Cuirass is to execute:
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
./pre-inst-env cuirass --specifications=examples/hello.scm ./pre-inst-env cuirass register --specifications=examples/hello.scm
#+END_EXAMPLE #+END_EXAMPLE
This will read the file "examples/hello.scm" which contains a list of This will read the file "examples/hello.scm" which contains a list of
@ -93,13 +93,13 @@ To resume the evaluation/build process you can execute the same command
without the '--specifications' option: without the '--specifications' option:
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
./pre-inst-env cuirass ./pre-inst-env cuirass register
#+END_EXAMPLE #+END_EXAMPLE
To start the web interface run: To start the web interface run:
#+BEGIN_EXAMPLE #+BEGIN_EXAMPLE
./pre-inst-env cuirass --web ./pre-inst-env cuirass web
#+END_EXAMPLE #+END_EXAMPLE
* Contributing * Contributing

View File

@ -357,26 +357,68 @@ This mode is harder to setup but scales way better. This is the build
mode that is used on the GNU Guix build farm at mode that is used on the GNU Guix build farm at
@url{https://ci.guix.gnu.org}. @url{https://ci.guix.gnu.org}.
It can be enabled by passing the @code{build-remote} command line It can be enabled this way:
argument, see @ref{Invocation}.
@itemize
@item
Start the @code{cuirass register} process with the @code{build-remote}
command line argument, see @ref{Invocation}. This way, the
registration process does not submit the new build jobs to the local
Guix daemon.
@item
Start the @code{cuirass remote-server} process to dispatch the build
jobs to the connected workers.
@item
Start at least one @code{cuirass remote-worker} process on any machine
of the local network to actually perform the builds and report their
status.
@end itemize
Note that some Cuirass features are only available when using this
build mode. That's the case for:
@itemize
@item
The build priority support.
@item
The notification mechanism, see @ref{Notifications}.
@item
The transmission of @code{timeout} and @code{max-silent-time} package
properties to the Guix daemon.
@item
The live build log mechanism of the Web interface.
@item
The workers status page of the Web inferface accessible at
@url{http://cuirass-url/workers}.
@end itemize
The easiest way to setup such an infrastructure is to rely on the GNU
Guix Cuirass services definitions (@pxref{Continuous Integration,
Continuous Integration,, guix, Guix}).
@c ********************************************************************* @c *********************************************************************
@node Invocation @node Invocation
@chapter Invocation @chapter Invocation
@section Invoking cuirass
@cindex invoking cuirass
The usual way to invoke @code{cuirass} is as follows: @section Invoking cuirass register
@cindex register
The usual way to invoke @code{cuirass} registration process is as follows:
@example @example
cuirass --specifications @var{specs} & cuirass register --specifications @var{specs}
cuirass --web &
@end example @end example
This starts a Cuirass instance building @var{specs} and storing the This starts a Cuirass registration instance building @var{specs} and
results using the default PostgreSQL database. The second command storing the results using the default PostgreSQL database.
starts a Cuirass web server, on the default port, using the same
database.
Additionally the following options can be used. Additionally the following options can be used.
@ -418,15 +460,6 @@ Those GC roots are typically stored in
@file{/var/guix/gcroots/profiles/per-user/@var{user}/cuirass}, where @var{user} is the @file{/var/guix/gcroots/profiles/per-user/@var{user}/cuirass}, where @var{user} is the
user under which Cuirass is running. user under which Cuirass is running.
@item --port=@var{num}
@itemx -p @var{num}
Make the HTTP interface listen on port @var{num}. Use port 8080 by
default.
@item --listen=@var{host}
Make the HTTP interface listen on network interface for @var{host}. Use
localhost by default.
@item --interval=@var{n} @item --interval=@var{n}
@itemx -I @var{n} @itemx -I @var{n}
Wait @var{n} seconds between each poll. Wait @var{n} seconds between each poll.
@ -453,7 +486,51 @@ Display the actual version of @code{cuirass}.
Display an help message that summarize all the options provided. Display an help message that summarize all the options provided.
@end table @end table
@section Invoking remote-server @section Invoking cuirass web
@cindex web
The usual way to invoke the @code{cuirass} web server is as follows:
@example
cuirass web
@end example
This starts a Cuirass web server on the default port. Additionally the
following options can be used.
@table @code
@item --database=@var{database}
@itemx -D @var{database}
Use @var{database} as the database containing the jobs and the past
build results. Since Cuirass uses PostgreSQL as a database engine,
@var{database} must be a string such as @code{"dbname=cuirass
host=localhost"}. By default, Cuirass uses the following connection
string: @code{dbname=cuirass host=/var/run/postgresql"}.
@item --parameters=@var{parameters-file}
@itemx -P @var{parameters-file}
Read parameters from the given @var{parameters-file}. The supported
parameters are described here (@pxref{Parameters}).
@item --port=@var{num}
@itemx -p @var{num}
Make the HTTP interface listen on port @var{num}. Use port 8080 by
default.
@item --listen=@var{host}
Make the HTTP interface listen on network interface for @var{host}. Use
localhost by default.
@item --version
@itemx -V
Display the actual version of @code{cuirass}.
@item --help
@itemx -h
Display an help message that summarize all the options provided.
@end table
@section Invoking cuirass remote-server
@cindex remote-server @cindex remote-server
The @code{remote-server} command starts a daemon that is able to The @code{remote-server} command starts a daemon that is able to
@ -512,7 +589,7 @@ Display the actual version of @code{cuirass}.
Display an help message that summarize all the options provided. Display an help message that summarize all the options provided.
@end table @end table
@section Invoking remote-worker @section Invoking cuirass remote-worker
@cindex remote-worker @cindex remote-worker
The @code{remote-worker} command starts a daemon that is able to The @code{remote-worker} command starts a daemon that is able to