adds 1337x and tpb latest scrapers

This commit is contained in:
TheBeastLT
2020-03-08 00:58:06 +01:00
parent 51eb21f112
commit 853c21472a
9 changed files with 457 additions and 432 deletions

View File

@@ -1,13 +1,14 @@
const { Sequelize } = require('sequelize');
const Op = Sequelize.Op;
const POSTGRES_URI = process.env.POSTGRES_URI || 'postgres://torrentio:postgres@localhost:5432/torrentio';
const DATABASE_URI = process.env.DATABASE_URI;
const database = new Sequelize(POSTGRES_URI, { logging: false });
const database = new Sequelize(DATABASE_URI, { logging: false });
const Provider = database.define('provider', {
name: { type: Sequelize.STRING(32), primaryKey: true },
lastScraped: { type: Sequelize.DATE }
lastScraped: { type: Sequelize.DATE },
lastScrapedId: { type: Sequelize.STRING(128) }
});
const Torrent = database.define('torrent', {