Git Product home page Git Product logo

covoiturage-libre's Introduction

README

CovoiturageLibre is a Carpooling Open Source platform, originally created for the French website https://covoiturage-libre.fr

It aims at providing a free, non-profit carpooling service for the shared economy, with no for-profit company controlling the service.

You can find the repository for the Android app just here.

Licence

We are currently discussing under which license we want to publish the covoiturage-libre code. Any reuse of the code must go through a strong speech with the staff members, do not hesitate to open an "Issue" to discuss it. We want the widest federated Project as possible, avoiding forks that do not COMMUNICATE WITH US. (Thus, the proposed car-sharing will be better)

The currently licence is the GNU GENERAL PUBLIC LICENSE v3.0, see LICENCE.

Install

  • Ruby and Rails version

ruby 2.3.1

rails 5.0.0

  • System dependencies (versions originally used on this project)

postgresql 9.5.3

postgis 2.2.2

elasticsearch 2.4

  • Configuration

Create a database.yml file

cp config/database.yml.example config/database.yml

NB : a simple postgresql config file does the jobs. The adapter is postgis but postgresql works as well.

  • Database creation

bundle exec rake db:create

  • Database initialization

Install postgis extension on your database :

user=> CREATE extension postgis;
CREATE EXTENSION

Then you can run the migrations

bundle exec rake db:migrate

Static pages

Some static pages are needed, normally created in the built-in CMS. The seedbank gem is used to import them (https://github.com/james2m/seedbank)

Just type :

rake db:seed:pages

to import them.

Cities

You must import a cities in order to be able to find cities in the search engine. You can just create a few cities if you want to make it work for local development, or ask me for the 80000 cities of the databse if you want. Searchkick is used in the search engine.

Setting up searchkick

We use searchkick as a search engine for Cities autocompletion.

Searchkick is based on elasticsearch, visit searchkick github page to set it up.

Once Elasticsearch is running, you have to index Geonames :

2 choices. Go in the console :

rails c
irb> City.reindex

or use the rake task :

rake searchkick:reindex CLASS=City

Delayed jobs

We use delayed_jobs_activerecord to process asynchronous jobs like delivering email.

You have to run it with the command :

./bin/delayed_job start

How to run the test suite

planning on using rspec

Services (job queues, cache servers, search engines, etc.)

in order to make the emails delivered, you have to start delayed_jobs

./bin/delayed_jobs start

covoiturage-libre's People

Contributors

flexbox avatar nicolasleger avatar pimpin avatar poussinou avatar teddfiction avatar u1735067 avatar uptip avatar

Watchers

 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.