defrex / django-encrypted-fields

This is a collection of Django Model Field classes that are encrypted using Keyczar.
MIT License
193 stars 60 forks source link

location of fieldkeys #20

Closed Awmusic12635 closed 8 years ago

Awmusic12635 commented 8 years ago

ENCRYPTED_FIELDS_KEYDIR = '/path/to/fieldkeys'

Is this relative to my project folder?

so / would be considered the top of my project folder.

defrex commented 8 years ago

It is not relative to your project folder. However, you can make it so thusly.

import os

PROJECT_DIR =os.path.dirname(os.path.dirname(__file__)) # assuming $PROJECT_DIR/somename/settings.py

ENCRYPTED_FIELDS_KEYDIR = os.path.join(PROJECT_DIR, 'mycoolpath/keys')