Giter Site home page Giter Site logo

xdbwb's Introduction

----------------------------------------------------------------------------
"THE BEER-WARE LICENSE" (Revision 42):
<vichak-at-hakoun-dot-fr> wrote this file. As long as you retain this notice you
can do whatever you want with this stuff. If we meet some day, and you think
this stuff is worth it, you can buy me a beer in return vichak
----------------------------------------------------------------------------

   _  __ ____  ____ _       ______ 
  | |/ // __ \/ __ ) |     / / __ )
  |   // / / / __  | | /| / / __  |
 /   |/ /_/ / /_/ /| |/ |/ / /_/ / 
/_/|_/_____/_____/ |__/|__/_____/  Xbmc Data Base Web Browser

(ascii generator slant )

Description

xdbwb is a personal project. Feel free to contribute to it.

xdbwb is a simple website that browse xbmc database.

This project is built with Python(2.7.3), django web framework(1.4.1) and jquery mobile framework(1.3.0). It uses your populated xbmc database (specified in xdbwb/settings.py).

Development and deployement is done on GNU/Linux host.

xdbwb/lib/models.py is generated with this django script, a few modifications were applied.

Needed packages

sudo apt-get install git python-pip python-dev libmysqlclient-dev
sudo pip install Django==1.4.1 MySQL-python

Setup development environment

  1. Get working dir
mkdir ~/working_dir
cd working_dir
git clone https://github.com/vichak/xdbwb.git
cd xdbwb
  1. Generate your secret key on http://www.miniwebtool.com/django-secret-key-generator/

Edit SECRET_KEY variable in xdbwb/settings.py

Commit your change

git add xdbwb/settings.py
git commit -m "Set SECRET_KEY value"
  1. Clone the git repo of JQuery-Mobile-Icon-Pack in static directory or download it
cd static
git clone https://github.com/commadelimited/jQuery-Mobile-Icon-Pack.git
cd ..
  1. Create xdbwb's database:
python manage.py syncdb

Save superuser login/password

  1. Define xbmc database location:

Use django syntax https://docs.djangoproject.com/en/dev/ref/databases/ example of mysql xbmc database in xdbwb/settings.py

  1. Download poster via Python script download_poster.py. xbmc database is used.
mkdir -p static/img
python download_poster.py -d static/img/
  1. Run development server
python manage.py runserver

Setup production environment

Apache2 + mod_wsgi for django website and lighttpd for serve static files (imgs/js/css).

  1. Get xdbwb in /var/www
sudo mkdir -p /var/www
cd /var/www
sudo git clone /home/vichak/working_dir/xdbwb
  1. Set production variables in /var/www/xdbwb/xdbwb/settings.py
DEBUG = FALSE
PROJECT_PATH = '/var/www/xdbwb/'
  1. Get database from development environment
sudo cp /home/vichak/working_dir/xdbwb/xdbwb.db /var/www/xdbwb
  1. Install apache2 + mod_wsgi
sudo apt-get install apache2 libapache2-mod-wsgi
  1. Configure xdbwb in apache2
sudo chown -R www-data. /var/www
sudo chmod u+x /var/www/xdbwb/conf/xdbwb.wsgi
sudo cp /var/www/xdbwb/conf/xdbwb /etc/apache2/sites-available
sudo a2dissite default
sudo a2ensite xdbwb
  1. Install static lighttpd server
sudo apt-get install lighttpd
  1. Collect static files from development environment
cd /home/vichak/working_dir/xdbwb/
python manage.py collectstatic
sudo cp -R /home/vichak/working_dir/xdbwb/static_for_prod /var/www/xdbwb_static
  1. Configure lighttpd
sudo cp /var/www/xdbwb/conf/lighttpd.conf /etc/lighttd/
  1. Configure production xdbwb

Edit /var/www/xdbwb/settings.py

STATIC_URL = 'http://<IP_ADDRESS>:81/'

Commit your change

git add xdbwb/settings.py
git commit -m "Set settings for production"
  1. Restart apache2 and lighttpd
sudo service apache2 restart
sudo service lighttpd restart

#TODO

####BUG########
1. multiple film in stack:///chemin/film/cd1 . /chemin/film/cd2
###############
utf-8
improve pagination
Writers/Actors
Streamdetails
Series
comments on a film
note a film
signal a problem with a movie
write tests
search form
internationalization
#####admin########
improve admin section //now olnly auth Movies
#####display######
apple-touch-icon optimize android and choose a new one
film detail => improve display
#####auth#########
user information // next accounts/profile
####project mgmt##
security https

xdbwb's People

Contributors

vichak avatar

Stargazers

akuiraz avatar  avatar

Watchers

James Cloos avatar  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.