dreamfactorysoftware / df-docker

Docker container for DreamFactory.
59 stars 56 forks source link

Missing data in DF when image is rebuilt -> due to changed APP_KEY #13

Closed philicious closed 8 years ago

philicious commented 8 years ago

The following ONLY happens when re-building the image and using a new container (and therefore having a NEW APP_KEY in .env file)

philicious commented 8 years ago

I enabled rewrite logging, but rewrites seem to work just fine. see https://gist.github.com/philicious/cf112d31f83a168627d08f099b196c3a

I also tried using the apache vhost conf as suggested here http://wiki.dreamfactory.com/DreamFactory/Installation/Linux/Apt but that didnt help either.

(I was able to narrow down the problems. I'll update above post)

philicious commented 8 years ago

@davidweiner-df could you shed some light into how the APP_KEY is used by DF? Are there any DB tables I could manipulate to make it work with a new APP_KEY? Or should I rather ensure APP_KEY never changes ?

philicious commented 8 years ago

see https://github.com/philicious/df-docker/commit/207d28e762c92d9f32f5691703573b1c30a0047f for a fix

drewpearce commented 8 years ago

@philicious the app key is used for two way hashing. Items that are stored in the db affected by the key include service usernames and passwords (such as database credentials) and private lookups. Since user's passwords are one way hashed, the app key does not affect these values.

philicious commented 8 years ago

fixed and merged with #22