Skip to content

jstesta/WikiRoulette

Repository files navigation

WikiRoulette

Wiki Randomness!

This is an experiment in accessing the Wikipedia WikiMedia API via PHP. It loads a small amount of data about a few random Wikipedia pages, and displays it to the user.

Setup

For Development

Requirements

Setup Guide

  1. Clone this repository into a new directory
  2. Install Composer into the new directory
  3. Run php composer.phar install to download the Laravel Homestead dependency
  4. If you don't have a personal SSH key set up, generate one with SSH
  5. Run vagrant up (the first time may take a while as it downloads the virtual machine image)
  6. After it finishes, SSH into the server ssh vagrant@127.0.0.1:2222 (password: vagrant) and continue from step 2 of the For Production setup guide
  7. The web page should now be accessable from http://localhost:8000

For Production

Requirements

  • A webserver: Apache or nginx
  • PHP >= 5.5.9 w/PDO extension installed
  • A SQL database: MySQL, SQLite, Postgres, etc.

Setup Guide

  1. Clone this repository into a new directory
  2. cd into the new directory and run the following steps:
  • cd wikiroulette/site
  • Install Composer here curl -sS https://getcomposer.org/installer | php
  • php composer.phar install
  • cp .env.example .env
  • php artisan key:generate
  • Set up your local database configuration in the file .env. You should also set APP_DEBUG=false if this were a real production environment
  • php artisan migrate to set up the database table
  1. (Production setup only) Set up your web server to serve files from the wikiroulette/site/public directory
  2. The web page should now be accessable from the browser

About

Wiki Randomness!

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages