Skip to main content

An easy way to setup a database site.

Project description

Install

  • Run virtualenv demoenv --no-site-packages

  • Run demoenv\Scripts\activate

  • Run pip install Django

  • Run django-admin startproject demo

  • Run pip install cosmicdb

Usage

  1. Add cosmicdb and requirements to your INSTALLED_APPS setting like this (your app must be first to override):

    INSTALLED_APPS = (
        'YOURAPPHERE',
        'cosmicdb',
        'dal',
        'dal_select2',
        'crispy_forms',
        'django_tables2',
        ... (rest of django apps)
    )
  2. Add cosmicdb.urls to your urls.py like this (put cosmicdb urls last):

    from django.conf.urls import url, include
    
    urlpatterns = [
        ...
        url(r'^', include('cosmicdb.urls')),
    ]
  3. Add cosmicdb settings to your settings.py like this:

    COSMICDB_SITE_TITLE = 'Demo Site'
    COSMICDB_ALLOW_SIGNUP = False
    AUTH_USER_MODEL = 'cosmicdb.User'
    LOGIN_URL = '/login/'
    CRISPY_TEMPLATE_PACK = 'bootstrap3'
    DJANGO_TABLES2_TEMPLATE = 'django_tables2/bootstrap-responsive.html'
    EMAIL_USE_TLS = True
    EMAIL_HOST = 'smtp.gmail.com'
    EMAIL_PORT = 587
    EMAIL_HOST_USER = 'test@test.com'
    EMAIL_HOST_PASSWORD = 'testpassword'
    DEFAULT_FROM_EMAIL = EMAIL_HOST_USER
    DEFAULT_FROM_EMAIL_NAME = COSMICDB_SITE_TITLE
  4. Run python manage.py migrate

  5. Run python manage.py collectstatic

  6. Run python manage.py createsuperuser

Requirements

Django>=1.11

Dev Notes

python setup.py sdist bdist_wheel

twine upload dist/cosmicdb-0.0.1*

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cosmicdb-0.0.9.tar.gz (4.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cosmicdb-0.0.9-py3-none-any.whl (4.5 MB view details)

Uploaded Python 3

File details

Details for the file cosmicdb-0.0.9.tar.gz.

File metadata

  • Download URL: cosmicdb-0.0.9.tar.gz
  • Upload date:
  • Size: 4.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for cosmicdb-0.0.9.tar.gz
Algorithm Hash digest
SHA256 0fcdc05efa8d4c1b3a99c9b4d8008ab96d74a32fd12ea811a1291306bd8892ee
MD5 9eabd38bb7ad6bf4fc8fc212fffa0491
BLAKE2b-256 e7f20fcdb0884001b98af1c9979900434fe6c3edd881152f561d758898f3fcf0

See more details on using hashes here.

File details

Details for the file cosmicdb-0.0.9-py3-none-any.whl.

File metadata

File hashes

Hashes for cosmicdb-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 d3ee1d63c6eaed60a1d3fd29f8a8eefe575e00d10c7fbc9378a92f0443b734a9
MD5 cf13284e339251243c61fd9d624c03db
BLAKE2b-256 eb0cccd5b2ebfc41823bb00c9540d1d59ef57d92f644254db61955be4944563b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page