7 | | 1. Install Prerequisites |
8 | | * Install the prerequisite libraries. See the [wiki:Prereqs] page for more information. |
9 | | 1. Install Bcfg2 |
10 | | * '''From packages:''' The easiest way to install Bcfg2 is from packages for your operating system. You can grab packages (and source packages) for various OSes from the [wiki:Download] page. Install them as you would any other packages. The server package only needs to be installed on your designated Bcfg2 server machine; the clients package needs to be installed on any machine you plan to manage by Bcfg2. |
11 | | * '''From source:''' The Bcfg2 source tarball can also be grabbed from the [wiki:Download] page. After untarring the file, you can build Bcfg2 with {{{python setup.py install --prefix=/install/prefix}}} This will install both the client and server on that machine. |
| 8 | == Bcfg2 == |
| 9 | Before installing, you will need to choose a machine to be the Bcfg2 server. We recommend a Linux-based machine for this purpose, but the server will work on any supported operating system. Note that you may eventually want to run a web server on this machine for reporting and serving up package repositories. |
| 10 | |
| 11 | * '''From packages:''' The easiest way to install Bcfg2 is from packages for your operating system. You can grab packages (and source packages) for various OSes from the [wiki:Download] page. Install them as you would any other packages. The server package only needs to be installed on your designated Bcfg2 server machine; the clients package needs to be installed on any machine you plan to manage by Bcfg2. |
| 12 | * '''From source:''' The Bcfg2 source tarball can also be grabbed from the [wiki:Download] page. After untarring the file, you can build Bcfg2 with {{{python setup.py install --prefix=/install/prefix}}} This will install both the client and server on that machine. |
14 | | |
15 | | Both the client and server read their configuration information from `/etc/bcfg2.conf`. If you installed from a package, you should have a default version of this file installed. If not, or if you installed from source, you can find one in the `examples/` directory of the Bcfg2 source distribution. |
16 | | |
17 | | 1. Run bcfg2-admin init |
18 | | * This step will automatically execute the remainder of the steps in this process, prompting for user input as required. See the QuickStart page for more details. |
19 | | |
20 | | 1. The `[server]` section |
21 | | * Point `repository` at the location of your Bcfg2 repository (where all of you configuratione elements will live). You can start out with [ftp://ftp.mcs.anl.gov/pub/bcfg/bcfg2-0.8-demo-repo.tar.gz example repository] if you need some inspiration. |
22 | | * `repository = /var/lib/bcfg2` |
23 | | * Choose the `structures` you want to make use of. The selection in the example configuration file should work fine until you have a complete repository set up. |
24 | | * `structures = Bundler,Base` |
25 | | * Choose the `generators` you want to use. Again, keeping the defaults is appropriate for a new installation. |
26 | | * `generators = SSHbase,Cfg,Pkgmgr,Svcmgr` |
27 | | 1. The `[statistics]` section |
28 | | * This section controls how statistics information is sent out. Set `sendmailpath` to the location of your sendmail binary |
29 | | * `sendmailpath = /usr/sbin/sendmail` |
30 | | 1. The `[communication]` section |
31 | | * Set the protocol you wish to use. The currently recommended choice is xmlrpc/ssl. |
32 | | * `protocol = xmlrpc/ssl` |
33 | | * Select a shared secret password for use between your clients and server |
34 | | * `password = roboconfig` |
35 | | * Generate an ssl certificate for client/server communication and set its location |
36 | | * `openssl req -x509 -nodes -days 1000 -newkey rsa:1024 -out bcfg2cert.pem -keyout bcfg2cert.pem` |
37 | | * `key = /etc/bcfg2cert.pem` |
38 | | 1. The `[components]` section |
39 | | * Set the URL for your Bcfg2 server. This tells clients where to find the server and tells the server what port to listen on. |
40 | | * `bcfg2 = https://config.example.com:6789` |
41 | | |
42 | | Once your bcfg2.conf file is complete and either the example repository or an empty skeleton repository are in place, you can start up the bcfg2 server: |
43 | | |
44 | | * `/etc/init.d/bcfg2-server start` |
45 | | |
46 | | Copy the config files out to the clients, and you are installed! Next step: get that repository working for your particular environment. |
| 15 | Once Bcfg2 is installed, head over to the [wiki:QuickStart] to get it configured and up-and-running. |