2012-03-27

Django 마이그레이션 1.3.1 -> 1.4

이번에 Django 기반으로 서비스하는 시스템을 1.3.1 에서 1.4 로 마이그레이션하였다. settings.py 에서 다음 2가지를 변경해주니, 잘 동작되는 것 같다. 사실, 이 외에도 몇가지 있으나, Django 가 불평은 하지 않았다. 그래도 미래를 위해서 미리 바꾸어주는 것이 좋을 것이다. https://docs.djangoproject.com/en/dev/releases/1.4/를 참고해서 시도해보자.


DATABASE

# 변경전
DATABASE_ENGINE = 'postgresql_psycopg2'
DATABASE_NAME = '디비이름'
DATABASE_USER = '사용자'
DATABASE_PASSWORD = '비밀번호'
DATABASE_HOST = '호스트'
DATABASE_PORT = '포트'

# 변경후
DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.postgresql_psycopg2',
        'NAME': '디비이름',
        'USER': '사용자',
        'PASSWORD': '비밀번호',
        'HOST': '호스트',
        'PORT': '포트',
    }
}

TEMPLATE_LOADERS

# 변경전
TEMPLATE_LOADERS = (
    'django.template.loaders.filesystem.load_template_source',
    'django.template.loaders.app_directories.load_template_source',
#     'django.template.loaders.eggs.load_template_source',
)

# 변경후
TEMPLATE_LOADERS = (
    'django.template.loaders.filesystem.Loader',
    'django.template.loaders.app_directories.Loader',
#     'django.template.loaders.eggs.Loader',
)

댓글 없음:

댓글 쓰기