Skip to content

Latest commit

 

History

History
58 lines (36 loc) · 1.86 KB

README.md

File metadata and controls

58 lines (36 loc) · 1.86 KB

Logs Analysis - Udacity

The python script included in this project performs a mock query to a database for a fictional news website. It uses psycopg2 to send PostgreSQL queries to the database. The database includes a list of articles, along with their urls and author IDs; a list of authors; and a logs table which logs every connection to the website as well as its status.

Getting Started

These instructions will get you a copy of the project up and running on your local machine.

Prerequisites

You will need to install/download the following prior to running this software:

Installing

Download the database here: LogsDatabase

Then extract the database into the root folder of this project (this is wherever you saved this project on your local machine).

Run your vagrant machine using the Vagrantfile provided with the project. This process can take a while.

vagrant up

Inside of the virtual machine navigate to

cd /vagrant

Once there, run the following command to add the SQL database to your virtual machine:

psql -d news -f newsdata.sql

Once the database is installed, run the folloing command to produce a report:

python report.py

That's it! Once the program appears to be finished, check the log.txt file.

Built With

Authors