* Update README.md.

This commit is contained in:
gardouille 2015-03-18 11:15:24 +01:00
parent ef02caca6e
commit 1b70b3a0d9
1 changed files with 74 additions and 4 deletions

View File

@ -31,12 +31,13 @@ The proxmox module automates installing Proxmox on Debian systems.
### What Proxmox affects:
* Package/service/configuration files for Proxmox
* A new `sources.list` file for Proxmox
* Package/service/configuration files for Proxmox.
* A new `sources.list` file for Proxmox.
* Proxmox's cluster (master and nodes).
* System repository
* The static table lookup for hostnames `hosts`
* The static table lookup for hostnames `hosts`.
* Users and group permissions for WebGUI.
* WebGUI's service (pveproxy)
* WebGUI's service (pveproxy).
* Kernel modules loaded at the boot time.
* OpenVZ's configuration file.
* OpenVZ's service.
@ -72,6 +73,73 @@ class { 'proxmox::hypervisor':
}
```
#### Create a cluster full KVM (for Ceph)
```
node "pve_node" {
# Install an hypervisor full KVM
class { 'proxmox::hypervisor':
pveproxy_allow => '127.0.0.1,192.168.0.0/24',
kvm_only => true,
cluster_master_ip => '192.168.0.201',
cluster_name => 'DeepThought',
}
# Access to PVE Webgui
proxmox::hypervisor::group { 'sysadmin': role => "Administrator", users => [ 'marvin@pam', 'arthur@pam' ] }
# SSH authorized keys between all nodes without passphrase (the module generate a key if not present)
ssh_authorized_key { 'hyper01':
ensure => present,
key => 'AAAAB3NzaC1yc2EAAAADAQABAAABAQDQxnLaBlnujnByt3V7YLZv1+PTjREJ3hphZFdCVNs9ebED55/kEAPmtJzcq2OL7qk8PajvhpB7efuZAatKeCdhILpFBKRrCo/q3MsQUSyaHbrGKs8Kkpz0EBHp1Tgpd8i1+kF1EzVPqT/euNcI6cA3fyMrvdgTI25BwFt93A6bBpf4We7A0l0Ba2nCAs5ekWyKKLh54GO7KBHlMmIzboYpxwgnFcbb9UhuyUz2J6PSC0K+P+hdMXY4dFk/lPMEXLgve/TTPYpgDxgxWMUaobCanwBWcXkZ4MdJw2Qs6TQ0v+cOxX3ogr78w69naGB3joJ4ll31WA+Uo0mcZU3ylFj3',
type => 'ssh-rsa',
user => 'root',
options => 'from="192.168.0.201"',
}
ssh_authorized_key { 'hyper02':
ensure => present,
key => 'AAAAB3NzaC1yc2EAAAADAQABAAABAQCxJeQ1R1rhPoig4jZLA8/Haru3nhVMgvDgO7nIqpwuPkDrheINVHOAd+DyQF0I2MtAjzg9gKfyix/cJ0cWMbd6/FdSVJ39dGYtNG9/YwTBcQiYwT0xS4NgJHzKrYE9PH2HEmjTmzcDeZ/u+IZjhO3Kyy9yZKcOhwV6fD+mzjQb4S2zsy67R/aoySbZjuoZYHrBrfjc66WbPbLtsFXIXuk46N376Y5sX37Bj17HhDEdP/lc9v939SswW1RZ2t1mVAjsMdsyBULDZk5av6Uj//YT1KuZBmBWkp7nPp1yt2ANPPGAnEW3oYjzXJd56Xtf3d0nbHOdHvMmIiV9fZyRUATd',
type => 'ssh-rsa',
user => 'root',
options => 'from="192.168.0.202"',
}
# Verify the authenticity of each hosts (/etc/ssh/ssh_host_{rsa,ecdsa}_key.pub)
sshkey { 'hyper01':
ensure => present,
host_aliases => [ 'hyper01.ipr.univ-rennes1.fr', '192.168.42.201' ],
key => 'AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBJ3TC6B3+eVbohjk662FwM/1YUCjMwMT9lmZcNcfllF9Vm082lMXtKix20elUCK9yJDpPWvzFiqdyhgqPAeCNt4=',
target => '/root/.ssh/known_hosts',
type => 'ecdsa-sha2-nistp256',
}
sshkey { 'hyper02':
ensure => present,
host_aliases => [ 'hyper02.ipr.univ-rennes1.fr', '192.168.42.202' ],
key => 'AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBEqUpnig3DIQVZEr3LxJCVEF/fl4n1s8LNuUUaLRueCW2ygzNBOv2m7O42K/Ok7aa4kjGaXbnneYXMw3wBULJ1U='
target => '/root/.ssh/known_hosts',
type => 'ecdsa-sha2-nistp256',
}
# If you don't have a DNS service, i recommend to have an entry for each nodes in the hosts file
host { 'hyper01':
name => "hyper01.${::domain}",
ensure => present,
ip => '192.168.42.201',
host_aliases => 'hyper01',
}
host { 'hyper02':
name => "hyper02.${::domain}",
ensure => present,
ip => '192.168.42.202',
host_aliases => 'hyper02',
}
}
node /hyper0[12]/ inherits "pve_node" {
}
```
Will create a Cluster Proxmox with name "Deepthought", the master will be "hyper01". You also can manage all ssh ressources (and host) manually on each nodes.
### VM
Only OpenVZ is supported right now but the vm's class will check-it by it self:
@ -149,6 +217,8 @@ proxmox::hypervisor::user { 'marvin':
* `vz_service_manage`: If set to 'true', Puppet will manage the OpenVZ's service. Can be 'true' or 'false'. Defaults to 'true'.
* `vz_service_enabled`: If set to 'true', Puppet will ensure the OpenVZ's service is running. Can be 'true' or 'false'. Defaults to 'true'.
* `labs_firewall_rule`: If set to 'true', Puppet will set a iptable rule to allow WebGUI and VNC's port access. Can be 'true' or 'false'. Defaults to 'false'.
* `cluster_master_ip`: The ip address of the "master" node that will create the cluster. Must be an IP address. Defaults to 'undef'.
* `cluster_name`: The cluster's name. Defaults to 'undef'.
#### proxmox::vm
* `vm_interfaces_path`: The main network configuration's file. Defaults to '/etc/network/interfaces'.