$ pip install Flask-Migrate
And on our main.py import and add Migrate
from flask_migrate import Migrate
from config import DevConfig| #!/usr/bin/python3 | |
| from tempfile import mkstemp | |
| from shutil import move, copymode | |
| from os import fdopen, remove | |
| import sys | |
| import pdb | |
| filename = sys.argv[-1] |
| import shutil | |
| import tempfile | |
| from django.conf import settings | |
| from django.core.files.storage import FileSystemStorage | |
| from django.db.models import FileField | |
| from django.db.models.loading import get_model, get_models | |
| from django.test.runner import DiscoverRunner |
| upstream tornadoFrontends { | |
| server 127.0.0.1:8000; | |
| server 127.0.0.1:8001; | |
| server 127.0.0.1:8002; | |
| server 127.0.0.1:8003; | |
| } | |
| server { | |
| listen 80; | |
| # We support all major PHP versions. Please see our documentation for a full list. | |
| # https://documentation.codeship.com/basic/languages-frameworks/php/ | |
| # By default we use the latest PHP version from the 5.5 release branch, but Laravel requires at least version 5.6.4 | |
| phpenv local 7.0 | |
| mysql -e 'create database tests_christian_landing;' | |
| #change in projects settings -> env variables -> add: COMPOSER_HOME | ${HOME}/cache/composer | |
| composer install --prefer-dist --no-interaction | |
| cp .env.codeship .env | |
| php artisan migrate --force |
| # $Id: Nielsen2012Python_case.py,v 1.2 2012/09/02 16:55:25 fn Exp $ | |
| # Define a url as a Python string (note we are only getting 100 documents) | |
| url = "http://wikilit.referata.com/" + \ | |
| "wiki/Special:Ask/" + \ | |
| "-5B-5BCategory:Publications-5D-5D/" + \ | |
| "-3FHas-20author%3DAuthor(s)/-3FYear/" + \ | |
| "-3FPublished-20in/-3FAbstract/-3FHas-20topic%3DTopic(s)/" + \ | |
| "-3FHas-20domain%3DDomain(s)/" + \ | |
| "format%3D-20csv/limit%3D-20100/offset%3D0" |
| mysql -u root -p | |
| CREATE USER 'homestead'@'localhost' IDENTIFIED BY 'some_pass'; | |
| GRANT ALL PRIVILEGES ON *.* TO 'homestead'@'localhost' WITH GRANT OPTION; | |
| CREATE USER 'homestead'@'%' IDENTIFIED BY 'some_pass'; | |
| GRANT ALL PRIVILEGES ON *.* TO 'homestead'@'%' WITH GRANT OPTION; | |
| FLUSH PRIVILEGES; | |
| <?php | |
| require_once __DIR__.'/vendor/autoload.php'; | |
| use Symfony\Component\HttpFoundation\Request; | |
| use Symfony\Component\HttpFoundation\Response; | |
| $app = new Silex\Application(); | |
| $app['debug'] = true; |