From 4eb426f70d149437c3e690ed553785040dd5e31d Mon Sep 17 00:00:00 2001 From: stephane Date: Thu, 19 Mar 2015 18:31:58 -0700 Subject: [PATCH] Add OpenID login provider support to Zanata config We want users to sign in using openstackid.org. This requires changes to the Zanata config to specify an OpenID provider and to disable the existing internal login so we don't wind up with multiple login buttons. Make OpenID configuration optional so others can still use the module without it. Also allow the admin user list to be configured. Change-Id: I3688688ef37fea602b107fba17dcc8d6f40f9275 --- manifests/init.pp | 2 ++ templates/standalone.xml.erb | 22 ++++++++++++++++------ 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/manifests/init.pp b/manifests/init.pp index b6c346e..10f8441 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -32,6 +32,8 @@ class zanata( $zanata_default_from_address = '', $zanata_storage_dir = '/home/wildfly/zanata', + $zanata_openid_provider_url = '', + $zanata_admin_users = '', ) { diff --git a/templates/standalone.xml.erb b/templates/standalone.xml.erb index a4726e8..8a39cb3 100644 --- a/templates/standalone.xml.erb +++ b/templates/standalone.xml.erb @@ -163,9 +163,9 @@ <%= @zanata_db_username %> - <% if @zanata_db_password != '' -%> +<% if @zanata_db_password != '' -%> <%= @zanata_db_password %> - <% end -%> +<% end -%> NOWARN @@ -413,14 +413,19 @@ +<% if @zanata_openid_provider_url == '' -%> +<% end -%> - +<% if @zanata_admin_users != '' -%> + +<% else -%> +<% end -%> - <% if @zanata_default_from_address != '' -%> +<% if @zanata_default_from_address != '' -%> - <% end -%> +<% end -%> @@ -445,7 +450,12 @@ - + + +<% if @zanata_openid_provider_url != '' -%> + +<% end -%> +