Django quickstart


###Installation

apt install libmysqlclient-dev

## Create requirements.txt files with following contents

```
django
django-adminlte2
mysqlclient
```
pip3 install -r requirements.txt

### database config

```

DATABASES = {
    # 'default': {
    #     'ENGINE': 'django.db.backends.sqlite3',
    #     'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
    # },
    'default': {
        'ENGINE': 'django.db.backends.mysql',
        'NAME': 'MartaliDial',
        'USER': 'martali',
        'PASSWORD': 'martalidbp@55',
        'HOST': 'thwinnet.cemuepnzjf0e.us-west-2.rds.amazonaws.com',
        'PORT': '3306',
    }
}

```

### Development
python3 manage.py runserver

python3 manage.py migrate
python3 manage.py createsuperuser

### Update database
python3 manage.py migrate [app]

Django quickstart was originally published on Thwin.Net

Advertisements

About herzcthu

I'm a translator of many cms and blogging software such as WordPress, Joomla. I'm administrator of WordPress Burmese official site. Founder of myanmapress.com

Posted on April 28, 2018, in Uncategorized. Bookmark the permalink. Leave a comment.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s

%d bloggers like this: