Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: README.md

Issue 4810150141493248: Issue 122 - Puppet ENC via Hiera (Closed)
Patch Set: 112 - Integrate run.py and monitoring with Hiera Created Feb. 26, 2015, 5:32 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « .hgignore ('k') | Vagrantfile » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: README.md
===================================================================
--- a/README.md
+++ b/README.md
@@ -6,17 +6,46 @@
Our Puppet manifests are only tested with Ubuntu 12.04 right now.
-Private files
--------------
+Host specific setup
+-------------------
-Some parts of our infrastructure are, obviously, confidential. We have
-htpasswd files, SSH keys and SSL certificates that we need to be
-careful with.
+Some infrastructure parts are specific to the environment (such as e.g.
+*development*, *test* and *production*) whilst passwords, for example,
+are confidential. In order to allow for such specific configuration, the
+repository requires a set of manual operations during the initial setup:
-That's why _modules/private_ is missing, and needs to be placed there
-manually. We provide stub versions of all those files in
-_modules/private-stub_, so just linking or copying that to
-_modules/private_ will make everything work locally.
+### `modules/private`
+
+The `private` module is destined to store confidential information such as
+[RSA](http://en.wikipedia.org/wiki/RSA_%28cryptosystem%29) keys, `htpasswd`
+files and so on. The repository provides a `private-stub` module containing
+defaults suitable for development and testing purpose. One can create a
+symbolic link to start using the resource:
+
+ # UNIX-oid
+ user@host:~/infrastructure$ ln -s private-stub modules/private
+
+ # Windows
+ C:\infrastructure\> MKLINK /D modules\private private-stub
+
+When creating a custom version, one may inspect the `modules/private-stub`
+directory to determine which resources have to be provided.
+
+### `hiera/private`
+
+Analogous to `modules/private`, [Hiera](https://docs.puppetlabs.com/hiera/1/)
+configuration files specific to the current environment are expected to be
+found in `hiera/private`. Default resources for development (and testing)
+purpose are provided within `modules/private-stub/hiera`:
+
+ # UNIX-oid
+ user@host:~/infrastructure$ ln -s ../modules/private-stub/hiera hiera/private
+
+ # Windows
+ C:\infrastructure\> MKLINK /D ..\modules\private-stub\hiera hiera\private
+
+Note that custom versions are recommended to be tracked together with the
+custom `private` module, if any.
Development environment
-----------------------
@@ -33,7 +62,7 @@
* [VirtualBox](https://www.virtualbox.org/)
* [Vagrant](http://vagrantup.com/)
-* _modules/private_ exists (see above)
+* Both `modules/private` and `hiera/private` exist (see above)
### Start a VM
@@ -64,24 +93,30 @@
The default password for this user (required for the _sudo_ command) is "test".
-Adding a server
----------------
+Adding a host
+-------------
-To set up a new server, you should first add it to the development
-environment and test the setup, then set up a corresponding production
-server.
+To set up a new host, extend the custom `hiera/private/host.yaml` by another
+`servers:` item, e.g.:
-### Development environment
+ # ...
+ custom1:
+ ip: [10.8.0.254]
+ dns: foobar.example.com
+ ssh_public_key: AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAA...
+ role: codereviewserver
-1. Add entries in _Vagrantfile_ and _manifests/vagrant.pp_
+See `modules/base/manifests/init.pp`, especially the `explicit_host_record()`
+named type within class `base`, for more information on the possible option
+keys and values.
-2. Add the host name to one of the manifests imported by
-_manifests/nodes.pp_
+Configuring Puppet
+------------------
-3. Make sure the server uses the _nagios::client_ class and add a
-_nagios\_host_ to _manifests/monitoringserver.pp_
+Below please find brief instructions for setting up Puppet on both master
+and agents:
-### Production environment
+### Prerequisites
1. Install Ubuntu Server 12.04 LTS
2. Perform an update and install Puppet
« no previous file with comments | « .hgignore ('k') | Vagrantfile » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld