Update install docs - DRBD module parameters

In the example ensure that the DRBD options are always passed to the
module even if it's loaded before /etc/modules is processed.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>
Fix the installation instructions for the DRBD module

The options for the DRBD module should not be duplicated in the case the
procedure is run multiple times.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Hrvoje Ribicic <riba@google.com>
Only check header for non-generated files

For generated files, it is enough to check the headers of the
files they are generated from. Moreover, the generated files
have the shebang-line of the target system, which might be
different from the generic one checked for.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Niklas Hambuechen <niklash@google.com>
Fix hlint warnings found by hlint 1.9.11

Our current hlint version cannot find them yet.

Signed-off-by: Niklas Hambuechen <niklash@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>

Cherry-picked from: d05f1c86fcca

Conflicts:
	src/Ganeti/Utils.hs (trivial)

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Niklas Hambuechen <niklash@google.com>
Merge branch 'stable-2.10' into stable-2.11

* stable-2.10
  Fix hlint warnings found by hlint 1.9.11
  Only check header for non-generated files

Conflicts:
	src/Ganeti/Utils.hs (trivial)

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Niklas Hambuechen <niklash@google.com>
Merge branch 'stable-2.11' into stable-2.12

* stable-2.11
  (no changes)

* stable-2.12
  Fix hlint warnings found by hlint 1.9.11
  Only check header for non-generated files

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>
Add "ignore-ipolicy" option to gnt-instance grow-disk

Unless the option is given, growing disks outside the ipolicy limits
will fail.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>
Add a helper function for checking the disk size ipolicy

The function only checks the disk-related parameters: The disk sizes
(and their count) and the disk template.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>
Test function ComputeIPolicyDiskSizesViolation

The class tests basic properties of the function.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>
Check disk size ipolicy during "gnt-instance grow-disk"

If a new disk size doesn't fit the ipolicy and --ignore-ipolicy is
given, just log warnings. If it's not, fail the operation.

Signed-off-by: Petr Pudlak <pudlak@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>
Merge branch 'stable-2.12' into stable-2.13

* stable-2.12
  Check disk size ipolicy during "gnt-instance grow-disk"
  Test function ComputeIPolicyDiskSizesViolation
  Add a helper function for checking the disk size ipolicy
  Add "ignore-ipolicy" option to gnt-instance grow-disk
  Fix the installation instructions for the DRBD module
  Update install docs - DRBD module parameters

* stable-2.11
  (no changes)

* stable-2.10
  Fix hlint warnings found by hlint 1.9.11
  Only check header for non-generated files

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Petr Pudlak <pudlak@google.com>