Compare commits

..

2 Commits

Author SHA1 Message Date
DebaucheryLibrarian
f96e938417 1.252.5 2026-04-04 00:19:10 +02:00
DebaucheryLibrarian
56169f00d6 Added feeds db table. Using undici agent for proxy. 2026-04-04 00:19:08 +02:00
4 changed files with 105 additions and 9 deletions

View File

@@ -0,0 +1,100 @@
exports.up = async function(knex) {
await knex.schema.createTable('feeds', (table) => {
table.increments('id');
table.integer('user_id')
.notNullable()
.references('id')
.inTable('users')
.onDelete('cascade');
table.string('name')
.notNullable();
table.string('slug')
.notNullable();
table.boolean('public');
table.boolean('primary');
table.text('comment');
table.json('meta');
table.datetime('created_at')
.notNullable()
.defaultTo(knex.fn.now());
});
await knex.schema.createTable('feeds_entities', (table) => {
table.increments('id');
table.integer('feed_id')
.notNullable()
.references('id')
.inTable('feeds')
.onDelete('cascade');
table.integer('entity_id')
.notNullable()
.references('id')
.inTable('entities')
.onDelete('cascade');
table.text('comment');
table.datetime('created_at')
.notNullable()
.defaultTo(knex.fn.now());
});
await knex.schema.createTable('feeds_actors', (table) => {
table.increments('id');
table.integer('feed_id')
.notNullable()
.references('id')
.inTable('feeds')
.onDelete('cascade');
table.integer('actor_id')
.notNullable()
.references('id')
.inTable('actors')
.onDelete('cascade');
table.text('comment');
table.datetime('created_at')
.notNullable()
.defaultTo(knex.fn.now());
});
await knex.schema.createTable('feeds_tags', (table) => {
table.increments('id');
table.integer('feed_id')
.notNullable()
.references('id')
.inTable('feeds')
.onDelete('cascade');
table.integer('tag_id')
.notNullable()
.references('id')
.inTable('tags')
.onDelete('cascade');
table.text('comment');
table.datetime('created_at')
.notNullable()
.defaultTo(knex.fn.now());
});
};
exports.down = async function(knex) {
await knex.schema.dropTable('feeds_tags');
await knex.schema.dropTable('feeds_actors');
await knex.schema.dropTable('feeds_entities');
await knex.schema.dropTable('feeds');
};

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{ {
"name": "traxxx", "name": "traxxx",
"version": "1.252.4", "version": "1.252.5",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "traxxx", "name": "traxxx",
"version": "1.252.4", "version": "1.252.5",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"@aws-sdk/client-s3": "^3.458.0", "@aws-sdk/client-s3": "^3.458.0",

View File

@@ -1,6 +1,6 @@
{ {
"name": "traxxx", "name": "traxxx",
"version": "1.252.4", "version": "1.252.5",
"description": "All the latest porn releases in one place", "description": "All the latest porn releases in one place",
"main": "src/app.js", "main": "src/app.js",
"scripts": { "scripts": {

View File

@@ -8,7 +8,6 @@ const fs = require('fs').promises;
// const util = require('util'); // const util = require('util');
// const stream = require('stream'); // const stream = require('stream');
const { pipeline } = require('stream/promises'); const { pipeline } = require('stream/promises');
const tunnel = require('tunnel');
const Bottleneck = require('bottleneck'); const Bottleneck = require('bottleneck');
const { JSDOM, toughCookie } = require('jsdom'); const { JSDOM, toughCookie } = require('jsdom');
const puppeteer = require('puppeteer-extra'); const puppeteer = require('puppeteer-extra');
@@ -328,11 +327,8 @@ const defaultAgent = new undici.Agent({
}, },
}); });
const proxyAgent = tunnel.httpsOverHttp({ const proxyAgent = new undici.ProxyAgent({
proxy: { uri: `http://${config.proxy.host}:${config.proxy.port}`,
host: config.proxy.host,
port: config.proxy.port,
},
}); });
async function request(method = 'get', url, body, requestOptions = {}, limiter, redirects = 0) { async function request(method = 'get', url, body, requestOptions = {}, limiter, redirects = 0) {