Make it Easier to Use Local Mirrors

Registered by Mark T. Voelker

Many users would prefer to use local mirrors of our package archives rather than reaching them via the internet (mostly because many users are behind odious proxy servers, but some also have no internet connectivity at all and still others just want the performance benefits of using local kit). This currently theoretically possible, but requires changes to a few bits of code. In order to make it easier for users to use local mirrors, we should inject some logic into the install scripts and/or Puppet manifests that allow them to more easily use local mirrors or both the Ubuntu archive and Cisco package repositories.

Off the top of my head, I think this means parameterizing the following (there may be more...we can add to this list as we discover them):

https://github.com/CiscoSystems/puppet_openstack_builder/blob/h.2/install-scripts/cisco.install.sh#L18-L19

https://github.com/CiscoSystems/puppet_openstack_builder/blob/h.2/data/hiera_data/vendor/cisco_coi_common.yaml#L22-L23

https://github.com/CiscoSystems/puppet-cobbler/blob/h.2/templates/preseed.erb#L2

https://github.com/CiscoSystems/puppet-cobbler/blob/h.2/manifests/ubuntu.pp#L24 (needs a "-m $url" added to it)

Blueprint information

Status:
Not started
Approver:
None
Priority:
Medium
Drafter:
Mark T. Voelker
Direction:
Needs approval
Assignee:
None
Definition:
New
Series goal:
None
Implementation:
Unknown
Milestone target:
milestone icon i.1

Related branches

Sprints

Whiteboard

1) Introduce another export variable called "repo" and "supplemental_repo" along with existing "vendor"
           Example:
                   Scenario 1: (Local mirror)
                          export vendor="local"
                          export repo="http://repo.myorganization.com"
                           export supplemental_repo="http://supplemental_repo.myorganization.com"

            Scenario 2: (use cisco mirror)
                          export vendor="cisco"

            Scenario 3: (use canonical mirror)
                          export vendor="canonical"
     2) Build a "local.install.sh" to point local repo. ( this script is similar to cisco.install.sh) This script would validate and expect for the variables "repo"
     3) create yaml for local repo "data/hiera_data/vendor/local_coi_common.yaml " and point to local repo

      4) put place holder for repo hostname in "preseed" file and the value would be configurable in user.yaml

      5) put a place holder for "local repo uri" in ubuntu.pp and the value can be configured in user.yaml

please let me know your thoughts on the above approach.

===============================
Previous conversations
===============================

I believe, we can leverage ISO builder script. ISO builder script does folloiwng:

1) It will bundle all required packages into ISO.
2) It will bundles COI scripts
3) It has scripts to load OS and setup local repo in the build node.
4) COI scripts will be pointing to local repo which is there in the same node.

We have contributed to ISO builder scripts and LiveCD. So we have knowledge on this.
please let me know if you are fine with this approach and we will also elaborate based on requirement.

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.