Coder Social home page Coder Social logo

smartclassroom-backend's Introduction

SmartClassRoom-Backend

  • REST Django Backend for cde2 Smart Classroom Challenge
  • REST API for wdb Mini Challenge 1

Run Django Server

  1. cd SmartClassRoom
  2. pip -r requirements.txt
  3. python manage.py runserver

Test REST API

  1. cd SmartClassRoom
  2. python manage.py test

build and push docker image

  1. docker build -t redstoner2014/smartclassroom-backend:latest .
  2. docker push redstoner2014/smartclassroom-backend:latest

Timescale Docker Installation

https://docs.timescale.com/install/latest/installation-docker/#set-up-the-timescaledb-extension

  1. Command:
docker run -d --name timescaledb -p 5432:5432 -v /your/data/dir:/var/lib/postgresql/data -e POSTGRES_PASSWORD=password timescale/timescaledb:latest-pg14
  1. add the database settings to the settings.py in the root dir:
DATABASES = {
        'default': {
            'ENGINE': 'timescale.db.backends.postgresql',
            'NAME': 'DBNAME',
            'USER': 'YOURDBUSER',
            'PASSWORD': 'YourPassword',
            'HOST': 'YOURLOCALPORT',
            'PORT': '5432',
            'TEST': {
                'NAME': 'smartclassroom_test_unittest',
            },
        }
    }

Django Admin Dashboard

http://127.0.0.1:8000/admin/

  • username: admin
  • password: Welcome12

Database Migration after Model Changes

  1. python manage.py makemigrations
  2. python manage.py migrate

Made with ❤️ and 🥥

smartclassroom-backend's People

Contributors

etiiir avatar yvokeller avatar florinbarbisch avatar gabrieltorresgamez avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.