packages/deb: build packages using the correct mirror (LP #1390416)

As of now Fuel related deb packages are built using the upstream mirror.
This yeilds inconsistent dependencies, for instance, packages depend on
both the upstream and the customized python versions, and provisioning of
Ubuntu node fails as a result.

To resolve the problem setup the build chroot using the official Fuel apt
repo. While at it use the locally created apt mirror instead of downloading
packages once more, and fix a number of inconsistencies/bugs.

* sandbox.mk:
  - sandbox define is modified so as to use local pre-built mirror.

* packages/deb/module.mk:
  - use the helper script to create build sandbox.

* requirements-deb.txt:
  - make sure tools required for building Debian packages are included
    into the local apt repo.

Change-Id: I9f7b06bba94a65b2d65168cc1122257f4bec78be
Related-bug: #1390416
Increase Fuel projects' versions

Should be merged at once with:

    https://review.openstack.org/#/c/137563/
    https://review.openstack.org/#/c/137557/
    https://review.openstack.org/#/c/137566/

Change-Id: I5627f4b0a17c5bf4c59bfdb9c6b1584a5d2f0c34
Closes-Bug: #1395279
Merge "Increase Fuel projects' versions"
Revert "Increase Fuel projects' versions"

This reverts commit 8d0da567292843a68a8df94d3da501eaba4e76de.

Change-Id: I205ae16a15e11aae9570518e33d4613f8f1851cd
Merge "Revert "Increase Fuel projects' versions""
Increase Fuel projects' versions

Should be merged at once with relevant patches to:

* fuel-web
* fuel-ostf
* fuel-astute

Change-Id: I9006c40ff181dc3d73b9432d66b6fec8c8c74cc5
Closes-Bug: #1395279
Fixed rebuilding docker containers

Change-Id: Id749943fa27573365f276565a8a23f8e7f6917d3
Closes-bug: 1395761
Merge "packages/deb: build packages using the correct mirror (LP #1390416)"
Add --installroot for yumdownloader to avoid evaluating system packages

When I'm trying build ISO under Fedora I have conflicts like:
Package: python-netaddr-0.7.12-6.2.mira1.x86_64 (proprietary)
    Requires: python(abi) = 2.6
    Installed: python-2.7.5-15.fc20.x86_64 (@updates)
        python(abi) = 2.7
        python(abi) = 2.7
    Installed: python3-3.3.2-18.fc20.x86_64 (@updates)
        python(abi) = 3.3
    Available: python-2.6.6-52.el6.x86_64 (proprietary)
        python(abi) = 2.6
It's because yumdownloader reads host RPMDB.

Change-Id: Ie7a70f3fd6f5098b97e3063c5cb32376a01d6843
Partial-Bug: #1396618
blueprint build-iso-on-fedora
Signed-off-by: Igor Gnatenko <ignatenko@mirantis.com>
Evaluate yum conflicts without duplicates

Enables Fedora to download packages more reliably.

Change-Id: I01ed8ce4863c8ed0fa75e7a6795ec7096ba14793
Partial-Bug: #1396618
blueprint build-iso-on-fedora
Signed-off-by: Igor Gnatenko <ignatenko@mirantis.com>
mirror/ubuntu: use aptly instead of custom scripts

Currently, we are building ubuntu mirror by 'multistrap', then
mkrepo.sh which copying .deb from /var/cache/, downloading
other .deb and .udeb and creating local mirror.

First point is multistrap is not available on RHEL, SUSE, etc.
Second point is building chroot, configuring pkgs, directly
downloading packages is slow and we can't maintenance this bullshit.

Now we will use one docker container, run 'aptly' inside, do mirror all
.udeb and .deb from requirements-deb.txt and pushing it to local_mirror/

blueprint build-iso-on-fedora
Signed-off-by: Igor Gnatenko <ignatenko@mirantis.com>

Change-Id: Ieb23c70f31633f651abc1f8700e039700dca669c
don't use multistrap when building deb packages

We want to get system where we will build .deb packages. Since this commit
we will use docker image.

blueprint build-iso-on-fedora
Signed-off-by: Igor Gnatenko <ignatenko@mirantis.com>

Change-Id: I2f00b8be1bb04fe644a75827113fe2fdd1c38a21