Add support for kickstarting different versions of a given datastore

Bug #1279098 reported by Viswa Vutharkar
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Trove Integration
In Progress
Medium
Viswa Vutharkar

Bug Description

In the function cmd_set_datastore() in redstack, which invokes trove-manage CLI to wire up an image to a specific datastore/version info in trove DB, there is ability to provide 'PACKAGES' string by defining an environment variable. This allows to override the default strings defined inside the function when running "redstack kick-start".

This enhancement aims to do the same thing for Version string as well, so that someone can do

export DATASTORE_VERSION="-2.4.9"; export PACKAGES="mongo-server"; redstack kick-start mongodb

This will be convenient when people are using redstack kick-start and want to give more flexible names to versions (Especially if they are pointing to an internal ubuntu package repo that pulls a different version during install than what is hardcoded in the redstack script)

Also allows version specific elements pick during image building. (See comment below for further details)

affects: trove → trove-integration
Changed in trove-integration:
assignee: nobody → Viswa Vutharkar (vvutharkar)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to trove-integration (master)

Fix proposed to branch: master
Review: https://review.openstack.org/72804

Changed in trove-integration:
status: New → In Progress
Revision history for this message
Viswa Vutharkar (vvutharkar) wrote : Re: Allow VERSION string to be specified externally when invoking kick-start

The git review submission

   Adds support to override VERSION string via env var

    Just like PACKAGES string can be overridden by supplying value via
    defining the environment variable prior to running redstack kick-start,
    the same facility is now extended to VERSION string as well.

    If the VERSION is not defined as env var, then the behavior is
    default. The code changes do not in any way alter the
    default behavior

    USAGE: export VERSION="-2.4.9"; redstack kick-start mongodb

    You may also want to set PACKAGES=" ", to prevent the triggering
    of Package update at guestagent prepare() time if you are
    already prebaking the required version you are interested in,
    into the dib image itself. The PACKAGES update at guestagent
    prepare() time is partially broken and you may want to avoid
    that path to get the desired version of your datastore installed
    and instead choose this VERSION string export mechanism

    This allows 3 things
    1) Specify the elements for your specific datastore version
       (:eg mongodb 2.4.9) to be picked by dib from the location
       scripts/files/elements/ubuntui-mongodb-2.4.9 rather than
       the default scripts/files/elements/ubuntui-mongodb when
       no VERSION is specified. This allows you for example to
       define a different install.d/* element for your specific
       datastore version if it is different from default

    2) when redstack invokes trove-manage to register the
       glance image with specific version in trove DB it will
       set the version for eg as 'mongodb-2.4.9'

    3) Also if you are taking advantage of dib tools or redstack
       kick-start in trove-integration to build your internal
       company specific image/version of your datastore and
       want to point these tools at your custom elements that
       might be installing packages from custom (non distro
       standard ) repos, then this change allows you to do
       so without impacting the standard behavior for the
       opensource trove-integration project

description: updated
description: updated
summary: - Allow VERSION string to be specified externally when invoking kick-start
+ Add support for kickstarting different versions of a given datastore
Changed in trove-integration:
importance: Undecided → Medium
milestone: none → juno-1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.