Consolidate xxx_password library routines in openstack-common

Bug #1195915 reported by Jay Pipes
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack + Chef
Fix Released
Wishlist
Andy McCrae

Bug Description

There's really no need to have >1 password retrieval library routine. Currently there are the following identical routines:

* secret
* db_password
* user_password
* service_password

They all do encrypted databag lookups in different databags. The names of the affected databags are controlled by attributes in the openstack-common/attributes/default.rb file.

These should be consolidated into a single "secret" library routine.

Changed in openstack-chef:
assignee: nobody → Andy McCrae (andrew-mccrae)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-block-storage (master)

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

Changed in openstack-chef:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-compute (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-dashboard (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-identity (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-image (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-metering (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-network (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-ops-database (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-ops-messaging (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-common (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-common (master)

Reviewed: https://review.openstack.org/66818
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-common/commit/?id=5e7592dc180bc30348afe7b1ecb3328d0fbacc5e
Submitter: Jenkins
Branch: master

commit 5e7592dc180bc30348afe7b1ecb3328d0fbacc5e
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 12:06:51 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that
    will accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password.

    Interim commit that keeps the service,db and user functions in order to
    merge other changes.

    Change-Id: Iba4a611b387d0975e8a23cc758d2ac7dec8210ad
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-image (master)

Reviewed: https://review.openstack.org/66805
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-image/commit/?id=501146b56d9616483a9611f6d7d698f9b404a2d5
Submitter: Jenkins
Branch: master

commit 501146b56d9616483a9611f6d7d698f9b404a2d5
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 11:23:34 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that will
    accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password

    Change-Id: I5093b7b4055ef0140dfbe36f96466cf0b38efc68
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-identity (master)

Reviewed: https://review.openstack.org/66802
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-identity/commit/?id=c4a0ff26bb92e9220cb347a210ab39b44ad298de
Submitter: Jenkins
Branch: master

commit c4a0ff26bb92e9220cb347a210ab39b44ad298de
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 11:06:10 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are
    redundant
    since they simply call "secret". Creates a get_password function that
    will accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password.

    Change-Id: I6879cac6731cc167592820caa811c2cc30660af0
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-network (master)

Reviewed: https://review.openstack.org/66814
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-network/commit/?id=66bfd986510f4d25c0574f27b8e5314a70809b31
Submitter: Jenkins
Branch: master

commit 66bfd986510f4d25c0574f27b8e5314a70809b31
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 11:55:27 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that
    will accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password.

    Change-Id: I480c654de44dc83e78f9ec4085f1b83edadd91d6
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-block-storage (master)

Reviewed: https://review.openstack.org/66797
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-block-storage/commit/?id=3fd80c0a3f156f27f3b83d4de9727e913ae9bdaf
Submitter: Jenkins
Branch: master

commit 3fd80c0a3f156f27f3b83d4de9727e913ae9bdaf
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 10:43:05 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that will
    accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password

    Change-Id: Ifdb5c7b3f590431aaa7ffc021cdee34899ac8c15
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-metering (master)

Reviewed: https://review.openstack.org/66806
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-metering/commit/?id=f7ac1e3599c6a621bda3ee97176737c3304e14da
Submitter: Jenkins
Branch: master

commit f7ac1e3599c6a621bda3ee97176737c3304e14da
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 11:28:26 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function thata will
    accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password

    Change-Id: Ia4dbfe4ff794efc84c900950a666085deebaf7f3
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-ops-messaging (master)

Reviewed: https://review.openstack.org/66817
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-ops-messaging/commit/?id=fbcfd04ff35cc0a3f419b7a2cb1f7876dab6831f
Submitter: Jenkins
Branch: master

commit fbcfd04ff35cc0a3f419b7a2cb1f7876dab6831f
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 12:00:27 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that will
    accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password

    Change-Id: Ic73c99034638ec092192d11e37671edbba0e48ef
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-ops-database (master)

Reviewed: https://review.openstack.org/66816
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-ops-database/commit/?id=aae68f9848539e589e8316634a362bfc1b210aed
Submitter: Jenkins
Branch: master

commit aae68f9848539e589e8316634a362bfc1b210aed
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 11:58:10 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that will
    accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password

    Change-Id: I8e1e25e73eb01cbea30435fe7c6c53cab7a15c04
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-compute (master)

Reviewed: https://review.openstack.org/66798
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-compute/commit/?id=cc385721e6a12eba3cacc770c85535ec26f7da39
Submitter: Jenkins
Branch: master

commit cc385721e6a12eba3cacc770c85535ec26f7da39
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 10:57:07 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that will
    accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password

    Change-Id: I3f37d2e940dfcaab8c40fe3d039cbd24239ffa42
    Partial-Bug: #1195915

Changed in openstack-chef:
assignee: Andy McCrae (andrew-mccrae) → Justin Shepherd (jshepher)
Changed in openstack-chef:
assignee: Justin Shepherd (jshepher) → Andy McCrae (andrew-mccrae)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-dashboard (master)

Reviewed: https://review.openstack.org/66801
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-dashboard/commit/?id=ce12ae273951e7c5825e049dc7aafc1abb7551ab
Submitter: Jenkins
Branch: master

commit ce12ae273951e7c5825e049dc7aafc1abb7551ab
Author: Andy McCrae <email address hidden>
Date: Wed Jan 15 11:02:48 2014 +0000

    Move to use "get_password" instead of "{user,service,db}_password"

    The user_password, service_password and db_password functions are redundant
    since they simply call "secret". Creates a get_password function that
    will accept a "type" of db, service or user.

    All instances of these calls have been changed to call get_password.

    Change-Id: I376297b7b8995d5c706e27a4388d2352343861db
    Partial-Bug: #1195915

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-common (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-common (master)

Reviewed: https://review.openstack.org/67804
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-common/commit/?id=4be974630f1e5cde45d32d382a453971658d670d
Submitter: Jenkins
Branch: master

commit 4be974630f1e5cde45d32d382a453971658d670d
Author: Andy McCrae <email address hidden>
Date: Mon Jan 20 10:40:19 2014 +0000

    Remove user_password, db_password and service_password

    All cookbooks are using "get_password" now, so removing the redundant
    functions as a "clean-up"

    Fixes bug: #1195915

    Change-Id: I2c651fdf43935263ea60bc48fa7785dd006c2940

Changed in openstack-chef:
status: In Progress → Fix Released
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.