Giter Site home page Giter Site logo

basgit's People

Contributors

lukaskalbertodt avatar

Watchers

 avatar  avatar  avatar

basgit's Issues

Transition to HTTPS

This is for the far future, but it's kind of important. Things to do:

  • Figure out how to run with/without HTTPS in different environments (localhost, server, ...)
  • Add certificate and all that jazz to the server
  • Configure diesel if necessary
  • Set all cookies to secure_only

Initial development roadmap

Instead of creating a dedicate issue for each of these, I'll collect ideas for initial development here.

Phase 0 (PR)

  • Minor cleanup & merge current progress into master
  • Update README.md and CONTRIBUTE.md to reflect the current status of the project
  • Make Travis work with diesel.rs and database stuff

Phase 1: User handling (PR)

  • DB connection pooling via r2d2 (r2d2-diesel)
  • Proper user session cookie
  • Proper login page with feedback on failure
  • User signup process (postponed: not that important now)
  • Maybe add "login via GitHub" (postponed: OAuth API of GitHub needs a fixed URL or something...)
  • Rather empty user page

Phase 2: Basic baskets (PR)

  • Teach the DB about "baskets"
  • List baskets of user on user page & list all existing baskets on the index page (temporary)
  • Form to create basket
  • Route for page showing the basket's contents (pretty empty at first)

Phase 3: Git

  • Create a git repository for each basket
    • probably important: think about where to put the repository
  • Show basic git information on basket page
  • Make it possible to traverse files of a basket's git repo
    • ... but don't spend too much time on that; this is not really the interesting part of this project. And while file browsing like on GitHub is somewhat needed for the end version, there should be more focus on the "facade" stuff.
    • Maybe even think about making git file browsing just another facade and add multiple item types to a basket... stuff like that
  • Think about making the git repository directly accessible
    • ... but again, don't spend too much time on this. If it turns out that a bit more complicated ssh server config is needed, this step should be skipped for now.
  • Probably as a requirement for facades and file browsing, I should think about a standard API interface. Of course REST & JSON is a de-facto standard, but it has a number of downsides. Apart from that, I should develop a system which makes it easy to pre render websites when first accessing then AND to update the site via JS by requesting data from the API. This is probably not easy at all, but should lie an important foundation for everything that follows. Keywords: Falcor by Netflix, GraphQL by Facebook.

Phase 4: Facades

  • Design the whole thing, basically.
  • Make bullet points for "Phase 4" more useful...
  • ...

At some time

  • Think about testing (click) (Do this rather early!)
  • Think about auto deploy to heroku via Travis-CI (see #12)
  • Develop a standard style which is similar to GitHub's but still notably different
  • Design a logo

Session improvements

Several things we might want to look at:

  • Enforce max session lifetime
  • Delete all old sessions from a given user on login (avoids multiple session entries per user)
  • Set correct cookie properties (lifetime, secure (see #9), ...)
  • Maybe manage session ids in a Rust internal collection instead of using the database. This should increase performance, but will invalidate all session cookies when the server is restarted (which is... ok maybe?)

Add database connection

This could be slightly tricky. For the database, we probably want to use:

  • diesel: a Safe, Extensible ORM and Query Builder
  • r2d2: a generic DB connection pool
  • r2d2-diesel: bridge between those two

Diesel can use multiple database backends, including PostgreSQL. We probably want to use that.

To make the connection pool available to all handlers, Rocket offers a "State" feature.

Improve Heroku Deploying

Deploying via Heroku kind of works, but here are some nice to haves:

  • Deploy to two different heroku uhm... thingies: one for development and one for "release"
  • Automatic DB migration handling

Testing

Rocket offers features to test more easily (click).

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.