(POOLER-71) Add dummy authentication provider

Previously it was difficult to do local development as VMPooler requires an LDAP
service for authentication. This commit adds a dummy authentication provider.
The provider has passes authentication if the username and password are
different, and fails if the username and password are the same.  This commit
also updates the documentation in the config YML file.
This commit is contained in:
Glenn Sarti 2017-01-26 15:05:38 -08:00
parent 48ed24a0de
commit d962886cf8
2 changed files with 26 additions and 3 deletions

View file

@ -56,6 +56,8 @@ module Vmpooler
def authenticate(auth, username_str, password_str)
case auth['provider']
when 'dummy'
return (username_str != password_str)
when 'ldap'
require 'rubygems'
require 'net/ldap'