Rename / prepare for merge with uncloud repo
This commit is contained in:
		
					parent
					
						
							
								23203ff418
							
						
					
				
			
			
				commit
				
					
						7a6c8739f6
					
				
			
		
					 118 changed files with 1499 additions and 0 deletions
				
			
		
							
								
								
									
										21
									
								
								uncloud_django_based/meow-payv1/config.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								uncloud_django_based/meow-payv1/config.py
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,21 @@
 | 
			
		|||
import os
 | 
			
		||||
 | 
			
		||||
from ungleich_common.ldap.ldap_manager import LdapManager
 | 
			
		||||
from ungleich_common.std.configparser import StrictConfigParser
 | 
			
		||||
from ungleich_common.etcd.etcd_wrapper import EtcdWrapper
 | 
			
		||||
 | 
			
		||||
config_file = os.environ.get('meow-pay-config-file', default='pay.conf')
 | 
			
		||||
 | 
			
		||||
config = StrictConfigParser(allow_no_value=True)
 | 
			
		||||
config.read(config_file)
 | 
			
		||||
 | 
			
		||||
etcd_client = EtcdWrapper(
 | 
			
		||||
    host=config.get('etcd', 'host'), port=config.get('etcd', 'port'),
 | 
			
		||||
    ca_cert=config.get('etcd', 'ca_cert'), cert_key=config.get('etcd', 'cert_key'),
 | 
			
		||||
    cert_cert=config.get('etcd', 'cert_cert')
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
ldap_manager = LdapManager(
 | 
			
		||||
    server=config.get('ldap', 'server'), admin_dn=config.get('ldap', 'admin_dn'),
 | 
			
		||||
    admin_password=config.get('ldap', 'admin_password')
 | 
			
		||||
)
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue