• Stars
    star
    126
  • Rank 284,543 (Top 6 %)
  • Language
    PHP
  • Created over 4 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Track movies or tv shows you watched.

iWatched

I am currently working on a new version which you can find in pull requests. Also here is a demo

iWatched is movie, tv series tracker for personal usage. iWatched uses imdb dataset. By a command it downloads all required datasets, unzips and imports to PostgreSQL database.

Import part is done by native PostgreSql command copy with Eloquent query builder. Part of the importing process also added weight column which will help ranking more accurately. You can find more information about imdb ranking algorithm here.

Searching

By default search is done by elasticsearch if you wish to search directly from database add ELASTICSEARCH=false variable to you .env file. Keep in mind database search is very slow.

ElasticSearch

You can use abc tool to import titles table. After that you will get pretty fast search results.

abc import --src_type=postgres --src_filter=titles --src_uri="postgresql://postgres:<your-password>@127.0.0.1:5432/<database-name>" "http://localhost:9200/titles"

Image of Searching

You can also use some shortcuts to find desired title.

the gift :year 2000
tt0903747 :imdb

Movies

Image of Movies

Series

Image of Series

Posters

Posters automatically fetched from themoviedb.org and stored at default storage.

Commands

php artisan import:titles

You can skip tables.

php artisan import:titles --skip=title

Or import only given tables.

php artisan import:titles --only=rating

Docker compose

Check .env.example file and be sure above ports not used.

PSQL_PORT=5439:5432
APP_PORT=8000:8000

Commands

docker-compose up -d

# If you getting any error when storage:link just remove public/storage folder.
docker-compose run --rm --no-deps iwatched-server php artisan storage:link
# This will migrate basic user tables.
docker-compose run --rm --no-deps iwatched-server php artisan migrate
# Downloads imdb dataset if its not already downloaded and imports to pgsql.
docker-compose run --rm --no-deps iwatched-server php artisan import:titles

You can now access app http://localhost:8000 with this url.

# If you start docker-compose recently please wait es cluster up and try again.
docker-compose run --rm --no-deps iwatched-server php artisan import:elastic

After first run you can start/stop app with below commands.

docker-compose start
docker-compose stop

TODO

  • Minio/AWS integration for posters.