Changeset 8781 for mauRepo/dj_security


Ignore:
Timestamp:
21/06/13 17:19:12 (6 years ago)
Author:
mnagni
Message:

Complete - # 22698: [CEDA Site Python Port] MyCEDA Login needs to be more user-friendly
 http://team.ceda.ac.uk/trac/ceda/ticket/22698
Incomplete - # 22852: [CEDA Site Python Port] ResReg? Index page
 http://team.ceda.ac.uk/trac/ceda/ticket/22852

Location:
mauRepo/dj_security/trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • mauRepo/dj_security/trunk

    • Property svn:ignore
      •  

        old new  
        66 
        77.pydevproject 
         8 
         9dist 
         10 
         11dj_security.egg-info 
  • mauRepo/dj_security/trunk/resources/dj_security_wsgi.conf

    r8768 r8781  
    1111    CustomLog LOG_DIR_PATH_PAR/PROJECT_NAME_PAR.log combined 
    1212 
    13     Alias /PROJECT_NAME_PAR/static/ PATH_TO_DJANGO_PROJECT_STATIC_FILES 
     13    Alias /PROJECT_NAME_PAR/static/ PROJECT_PATH_PAR 
    1414     
    15     <Directory PATH_TO_DJANGO_PROJECT_STATIC_FILES> 
     15    <Directory PROJECT_PATH_PAR> 
    1616        Order allow,deny 
    1717        Allow from all 
    18         Options Indexes FollowSymLinks 
    1918    </Directory> 
    2019     
    21     WSGIScriptAlias /PROJECT_NAME_PAR PATH_TO_PROJECT_WSGI/wsgi.py 
     20    WSGIScriptAlias /PROJECT_NAME_PAR PROJECT_PATH_PAR/resources/wsgi.py 
    2221 
  • mauRepo/dj_security/trunk/setup.py

    r8764 r8781  
    55import os 
    66 
    7 def collect_static(root_dir, dir_name, resources): 
    8     for dirpath, dirnames, filenames \ 
    9         in os.walk(os.path.join(root_dir, dir_name)): 
    10     # remove the 'cedatheme_mf54' part of the path 
    11         basepath = dirpath.split(os.path.sep, 1)[1] 
    12         resources.extend([os.path.join(basepath, filename) 
    13                  for filename in filenames]) 
    14  
    157base_name='dj_security' 
    168 
    179v_file = open(os.path.join(os.path.dirname(__file__),  
    1810                       base_name, '__init__.py')) 
     11 
    1912VERSION = re.compile(r".*__version__ = '(.*?)'", 
    2013                     re.S).match(v_file.read()).group(1) 
    2114 
    22 #This section collects the NOT PYTHON files to distribute 
    23 resources = [] 
    24 for dirpath, dirnames, filenames in os.walk(os.path.join(base_name, base_name)): 
    25     # remove the 'pytz' part of the path 
    26     basepath = dirpath.split(os.path.sep, 1)[1] 
    27     resources.extend([os.path.join(basepath, filename) 
    28                      for filename in filenames]) 
    29 for dir_name in ['static', 'templates']: 
    30     collect_static(base_name, dir_name, resources) 
    31      
    32 package_data = {base_name: resources} 
     15# allow setup.py to be run from any path 
     16os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) 
    3317 
    3418setup( 
     
    3721    author=u'Maurizio Nagni', 
    3822    author_email='maurizio.nagni@stfc.ac.uk', 
    39     package_dir = {base_name:base_name}, # tell distutils packages are under cedaMoles     
     23    include_package_data = True,      
    4024    packages=find_packages(), # include all packages under this directory     
    4125    url='http://proj.badc.rl.ac.uk/svn/ndg/mauRepo/dj_security',   
     
    5741                        'django-authopenid==1.0.1', 
    5842                        'userdb_model', 
    59                         'lxml'], 
    60      package_data=package_data,  
     43                        'lxml'],  
    6144) 
Note: See TracChangeset for help on using the changeset viewer.