Move alembic part in refstack/db/migrations

Make preparation for future encapsulation database logic
and best structurisation of RefStack project.
Move alembic related part in refstack/db/migrations.

Change-Id: I8e35e6d78227a4e901dcbf85bb7dc56211688a52
This commit is contained in:
Vladislav Kuzmin 2015-01-21 11:24:40 +04:00
parent e9902d7168
commit 7c121b3562
8 changed files with 3 additions and 2 deletions

View File

@ -24,6 +24,8 @@ Update the "app_address" parameter in the config.json file to the correct addres
Setup or update the database
`cd refstack/db/migrations`
NOTE: you are going to have to modify the db connection string in `alembic.ini` to get this working
PROTIP: if you just want to test this out, use `-n alembic_sqlite` to make a local sqlite db

0
refstack/db/__init__.py Normal file
View File

View File

View File

@ -15,8 +15,7 @@
# License for the specific language governing permissions and limitations
# under the License.
from __future__ import with_statement
import sys
sys.path.append("./")
from alembic import context
from sqlalchemy import engine_from_config, pool