Git Product home page Git Product logo

ergast-f1-api's Introduction

Ergast nodeJS API

In this period we are working to improve the server, specifically we want to make it faster in response times. After analyzing our current architecture we realized that using PHP is not the best and therefore we are moving to nodeJS. If you have any advice on how to improve the javascript code we are happy to hear your proposal. The current repository to find these files and how to install the server is located in this repository

ergast Local API Server

Based on the ergast-f1-api, a PHP-based API using the Ergast Formula One MySQL database developed by Chris Newell.

Instructions for Use Using Docker Compose

  • install docker
  • download and unzip the contents repository
  • cd into the root folder and run: docker-compose up --build -d --remove-orphans
  • give everything a minute or to to come up and then test the API at: http://localhost:8000/api/f1/2017.json

Instructions For Configuring API Server Independently

Assumes: Apache with PHP 5

Obtain a MySQL database image from: http://ergast.com/mrd/db/

Restore the database and set the username and password for a user with read-only privileges in f1dbro.inc

Under Apache, ensure that mod_rewrite is available. Enable AllowOverride All to support directory based rewrites, and add a rewrite rule to the .htaccess file in the root directory of the server e.g.

<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteRule ^api/(.*) /php/api/index.php [L]
</IfModule>

This example assumes the API code is installed in /php/api and the desired location of the API is /api

ergast-f1-api's People

Contributors

edivad99 avatar jcnewell avatar psychemedia 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.