Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Codesters

 Codesters

This presentation describes the development of Codesters.org and what did we learn from it.

Karambir Singh Nain

October 21, 2013

Transcript

34 slides
  1. Aim of the Project  becoming de-facto destination for programmers/

    learners  taking pain of searching resources from students  creating a common platform for students, content creators and Universities
  2. What we offer now:  Resource listings on basis of:

    o Types like books, ebooks, tutorials, online courses o Topics like Programming, Db, Web Technologies o Difficulty level: Beginner, Intermediate, Advanced  Every Programming topic introduction for beginners  Comments for discussion about a resource
  3. Some stats  more than 5000 monthly visitors  More

    than 6000 users across the wold  more than 500 books, ebooks, tutorials and online courses listed in less than 5 months  17 people have used our code to develop their own web app
  4. Our Software Stack  Web Server - Nginx with Gunicorn

     OS - Linux (ubuntu)  Programming Language - Python  Web Framework - Django  Database - MySQL  Other Dependencies - Git, pip, Twitter Bootstrap, Jquery, ElasticSearch.
  5. Why Linux and Nginx?  Linux: o Customizable (open source)

    o Free o Easy Integration o Availability  Nginx: o Lightweight o Serve Static files faster than Apache o Integrate with Python WSGI easily
  6. Python!!! No PHP or ASP.NET?  we love Python 

    PHP is from Iron Age of Internet  writing PHP/ASP is like writing static site: o with every page we see, there is one PHP file attached  python is more Dynamic  work as expected (unlike PHP)  Not Controlled by one Company(unlike ASP)
  7. What is Django  is a Python Web-Framework  is

    not like Wordpress or CMS  makes web-app development pleasurable
  8. Django Overview...  Models o Database - store data o

    Integrate with SQLite, MySQL, PostgreSQL, Oracle o Have its on database API  Template o highly customizable templating language o differentiate logic from presentation  Views o python functions to respond tp requests o handle what visitor see
  9. Git and pip  Git o is a distributed revision

    control o keep us in sync o full control over code  pip o manages python packages o switching between development and production makes easy
  10. Planning Phase March '13  brainstormed and discussion on ideas

     coming up with this  discussion about core features  made diagrams and wireframes of app
  11. Initial Dev May '13  made html mockups  discussed

    softwares to use  two weeks, we produced a crude  tested it a bit  Released Alpha Version in 4 weeks
  12. Development Phase June '13  Made some architectural changes 

    Used more of JavaScript and Jquery  Implemented Search feature with ElasticSearch  redesigned with Bootstrap  released version 1.0 on our Web Server
  13. Final Testing Late June '13  made user signups available

     included autmated emails per week for users  bugs for older browsers fixed  made available for mobile browsers
  14. Code Structure  manage.py  wsgi.py  settings.py  urls.py

     views.py  resource app o models.py o views.py  static files  templates
  15. Inside working - Urls.py  urls.py > gate keeper and

    receptionist  decides which function to call for request  uses Regular Expressions  raises 404 error if no match found
  16. Inside working - Views.py  are simple python functions 

    have all the function for app  check request type and process it  can query database if needed
  17. Inside working - Models.py  defines database for app 

    uses python classes to represent db tables  python method makes them more useful  gives db-api to query database in pythonic way
  18. Inside working - Templates  mini-language for defining the user-facing

    layer of app  separate logic and presentation Steps:  receives input from views as data  fill its file with data  send back output to view function for display
  19. VPS for hosting  we deploy with git and flask

     just one command and application deployed flask prod_deploy  uses Fabfile for settings and commands
  20. Technical learning  Python  Django  Linux Server Administration

     MySQL Administration  JavaScript/AJAX  Automation Tasks
  21. Entrepreneurial learning  what it takes to run Web App

     marketing a product  managing users and people  talking with companies and organizations  team work

More Decks by Karambir Singh Nain

Other Decks in Programming