Changeset 2367 for trunk


Ignore:
Timestamp:
Feb 9, 2013, 5:16:09 PM (11 years ago)
Author:
cereslee
Message:
Modified django autoinstaller to use my.cnf

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/locker/deploy/bin/django

    r2310 r2367  
    5959  if (/Your Name/) {
    6060    $_ = "    ('$USER', '$email'),";
     61  } elsif (/^DEBUG = /) {
     62      $_ =~ s/DEBUG/import os\n\nDEBUG/;
    6163  } elsif (/'ENGINE'/) {
    6264    $_ = "        'ENGINE': 'django.db.backends.mysql',";
     
    6466    $_ = "        'NAME': '$sqldb',";
    6567  } elsif (/'USER'/) {
    66     $_ = "        'USER': '$sqluser',";
     68    $_ = "        'OPTIONS': {\n            'read_default_file' : os.path.expanduser('~/.my.cnf'),\n        },";
    6769  } elsif (/'PASSWORD'/) {
    68     $_ = "        'PASSWORD': '$sqlpass',";
     70      next;
    6971  } elsif (/'HOST'/) {
    70     $_ = "        'HOST': '$sqlhost',";
     72      next;
    7173  } elsif (/Chicago/) {
    7274    $_ =~ s/Chicago/New_York/;
Note: See TracChangeset for help on using the changeset viewer.