Make Launchpad credentials reusable

Refactor and rename our Launchpad "sync" credentials (they haven't
been used to synchronize group membership from LP to Gerrit for
nearly 4 years now) which currently perform bug updates for
new/merged changes, so that they can be reused in the future to
update bugs as a part of release automation jobs.

Change-Id: Icd08dffef88fc8e99683d991ac6ac88b93bcb3e6
This commit is contained in:
Jeremy Stanley 2016-08-17 18:29:36 +00:00
parent 8e4a7c3382
commit 9a612ee9bc
5 changed files with 21 additions and 21 deletions

View File

@ -52,9 +52,9 @@ node 'review.openstack.org' {
ssh_welcome_rsa_pubkey_contents => hiera('welcome_message_gerrit_ssh_public_key'),
ssh_replication_rsa_key_contents => hiera('gerrit_replication_ssh_rsa_key_contents'),
ssh_replication_rsa_pubkey_contents => hiera('gerrit_replication_ssh_rsa_pubkey_contents'),
lp_sync_consumer_key => hiera('gerrit_lp_consumer_key'),
lp_sync_token => hiera('gerrit_lp_access_token'),
lp_sync_secret => hiera('gerrit_lp_access_secret'),
lp_access_token => hiera('gerrit_lp_access_token'),
lp_access_secret => hiera('gerrit_lp_access_secret'),
lp_consumer_key => hiera('gerrit_lp_consumer_key'),
contactstore_appsec => hiera('gerrit_contactstore_appsec'),
contactstore_pubkey => hiera('gerrit_contactstore_pubkey'),
swift_username => hiera('swift_store_user', 'username'),
@ -89,9 +89,9 @@ node 'review-dev.openstack.org' {
ssh_project_rsa_pubkey_contents => hiera('gerrit_dev_project_ssh_rsa_pubkey_contents'),
ssh_replication_rsa_key_contents => hiera('gerrit_dev_replication_ssh_rsa_key_contents'),
ssh_replication_rsa_pubkey_contents => hiera('gerrit_dev_replication_ssh_rsa_pubkey_contents'),
lp_sync_consumer_key => hiera('gerrit_dev_lp_consumer_key'),
lp_sync_token => hiera('gerrit_dev_lp_access_token'),
lp_sync_secret => hiera('gerrit_dev_lp_access_secret'),
lp_access_token => hiera('gerrit_dev_lp_access_token'),
lp_access_secret => hiera('gerrit_dev_lp_access_secret'),
lp_consumer_key => hiera('gerrit_dev_lp_consumer_key'),
storyboard_password => hiera('gerrit_dev_storyboard_token'),
storyboard_ssl_cert => hiera('gerrit_dev_storyboard_ssl_crt'),
}

View File

@ -71,10 +71,10 @@ class openstack_project::review (
# welcome-message's user ssh key.
$ssh_welcome_rsa_key_contents='',
$ssh_welcome_rsa_pubkey_contents='',
# To be renamed - they're now just launchpad creds, not lp_sync
$lp_sync_consumer_key='',
$lp_sync_token='',
$lp_sync_secret='',
# Launchpad creds for bug/blueprint updates
$lp_access_token='',
$lp_access_secret='',
$lp_consumer_key='',
# For gerrit's contactstore feature
# https://review.openstack.org/Documentation/config-contact.html
$contactstore = true,
@ -334,7 +334,7 @@ class openstack_project::review (
owner => 'gerrit2',
group => 'gerrit2',
mode => '0600',
content => template('openstack_project/gerrit_lp_creds.erb'),
content => template('openstack_project/infra_lp_creds.erb'),
replace => true,
require => User['gerrit2'],
}

View File

@ -19,9 +19,10 @@ class openstack_project::review_dev (
# SSH key for outbound ssh-based replication.
$ssh_replication_rsa_key_contents='',
$ssh_replication_rsa_pubkey_contents='',
$lp_sync_consumer_key = '',
$lp_sync_token = '',
$lp_sync_secret = '',
# Launchpad creds for bug/blueprint updates
$lp_access_token = '',
$lp_access_secret = '',
$lp_consumer_key = '',
$swift_username = '',
$swift_password = '',
$storyboard_password = '',
@ -228,7 +229,7 @@ class openstack_project::review_dev (
owner => 'gerrit2',
group => 'gerrit2',
mode => '0600',
content => template('openstack_project/gerrit_lp_creds.erb'),
content => template('openstack_project/infra_lp_creds.erb'),
replace => true,
require => User['gerrit2'],
}

View File

@ -1,6 +0,0 @@
[1]
consumer_key = <%= lp_sync_consumer_key %>
consumer_secret =
access_token = <%= lp_sync_token %>
access_secret = <%= lp_sync_secret %>

View File

@ -0,0 +1,5 @@
[1]
access_token = <%= lp_access_token %>
access_secret = <%= lp_access_secret %>
consumer_key = <%= lp_consumer_key %>
consumer_secret =