Fixed domain for index
This commit is contained in:
parent
8e4bfbcf0e
commit
6136e709c7
|
@ -53,7 +53,7 @@ RUN set -o pipefail \
|
|||
&& echo -e "#!/bin/bash\nsleep \$((60 + RANDOM % 60));\n/usr/bin/cinemapress container reindex save >> /home/\${CP_DOMAIN}/log/backup_\$(date '+%d_%m_%Y').log;\nsleep \$((30 + RANDOM % 60));\n/usr/bin/cinemapress container backup create >> /home/\${CP_DOMAIN}/log/backup_\$(date '+%d_%m_%Y').log;\nrm -f /home/\${CP_DOMAIN}/log/cron_movies.pid;\nfind /home/\${CP_DOMAIN}/log -mindepth 1 -mtime +14 -delete;" \
|
||||
> /etc/periodic/daily/backup \
|
||||
&& chmod a+x /etc/periodic/daily/backup \
|
||||
&& echo -e "#!/bin/bash\n/usr/bin/cinemapress container cron >> /home/\${CP_DOMAIN}/log/cron_\$(date '+%d_%m_%Y').log" \
|
||||
&& echo -e "#!/bin/bash\nsleep \$((RANDOM % 300));\n/usr/bin/cinemapress container cron >> /home/\${CP_DOMAIN}/log/cron_\$(date '+%d_%m_%Y').log" \
|
||||
> /etc/periodic/hourly/cron \
|
||||
&& chmod a+x /etc/periodic/hourly/cron
|
||||
EXPOSE 3000 3306
|
||||
|
|
|
@ -10,7 +10,7 @@ setTimeout(function() {
|
|||
setTimeout(function() {
|
||||
return process.exit(0);
|
||||
}, 1000 * 60 * 2);
|
||||
}, 1000 * 60 * 54);
|
||||
}, 1000 * 60 * 52);
|
||||
|
||||
/**
|
||||
* Node dependencies.
|
||||
|
@ -133,7 +133,7 @@ if (
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.scraper = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
async.eachOfLimit(
|
||||
modules.content.data.scraper.split('\n'),
|
||||
|
@ -412,7 +412,7 @@ if (
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.content = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
var task_groups = {};
|
||||
modules.content.data.custom.forEach(function(task) {
|
||||
|
@ -663,7 +663,7 @@ if (
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.episode = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
async.eachOfLimit(
|
||||
modules.episode.data.index.custom,
|
||||
|
@ -1018,7 +1018,7 @@ if (
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.publish = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
process.env['CP_VER'] = new Date().getTime().toString();
|
||||
|
||||
|
@ -1403,7 +1403,7 @@ if (
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.checkdomain = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
setTimeout(function() {
|
||||
request(
|
||||
|
@ -1682,7 +1682,7 @@ if (
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.imap = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
var options_imap = JSON.stringify(modules.abuse.data.imap);
|
||||
options_imap = JSON.parse(options_imap);
|
||||
|
@ -2109,7 +2109,7 @@ if (hour === 1 || hour === 2 || hour === 4 || hour === 5) {
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.sitemap = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
var year_start = new Date(timeZone).getFullYear() + 10;
|
||||
var year_stop = 1890;
|
||||
|
@ -2292,7 +2292,7 @@ if (hour === 6) {
|
|||
setTimeout(function() {
|
||||
active.num--;
|
||||
active.process.categories = false;
|
||||
}, 1000 * 60 * 55);
|
||||
}, 1000 * 60 * 53);
|
||||
|
||||
var categories = ['year', 'genre', 'country', 'actor', 'director'];
|
||||
|
||||
|
|
|
@ -2170,9 +2170,14 @@ if (Math.ceil(os.freemem()) < 50) {
|
|||
}
|
||||
connection.query(
|
||||
'SELECT * FROM ' +
|
||||
(task.page === 'xmlpipe2' ? 'xmlpipe2' : 'rt') +
|
||||
'_' +
|
||||
config.domain.replace(/[^a-z0-9]/g, '_') +
|
||||
(task.page === 'xmlpipe2'
|
||||
? 'xmlpipe2_' +
|
||||
config.domain.replace(/[^a-z0-9]/gi, '_')
|
||||
: 'rt_' +
|
||||
config.database.all_movies.replace(
|
||||
/[^a-z0-9]/gi,
|
||||
'_'
|
||||
)) +
|
||||
' WHERE ' +
|
||||
w +
|
||||
' LIMIT 0,1 OPTION max_matches = 1',
|
||||
|
@ -2184,9 +2189,11 @@ if (Math.ceil(os.freemem()) < 50) {
|
|||
}
|
||||
connection.query(
|
||||
'SELECT * FROM ' +
|
||||
'rt' +
|
||||
'_' +
|
||||
config.domain.replace(/[^a-z0-9]/g, '_') +
|
||||
' rt_' +
|
||||
config.database.all_movies.replace(
|
||||
/[^a-z0-9]/gi,
|
||||
'_'
|
||||
) +
|
||||
' WHERE ' +
|
||||
w +
|
||||
' LIMIT 0,1 OPTION max_matches = 1',
|
||||
|
|
|
@ -96,8 +96,9 @@ function movieApi(query, ip, callback) {
|
|||
connection.query(
|
||||
'SELECT * ' +
|
||||
(as && as.length ? ', ' + as.join(',') : '') +
|
||||
' FROM rt_' +
|
||||
config.domain.replace(/[^a-z0-9]/g, '_') +
|
||||
' FROM ' +
|
||||
' rt_' +
|
||||
config.database.all_movies.replace(/[^a-z0-9]/gi, '_') +
|
||||
' WHERE ' +
|
||||
Object.keys(query)
|
||||
.map(function(key) {
|
||||
|
@ -176,7 +177,7 @@ function moviesApi(query, ip, callback) {
|
|||
}
|
||||
connection.query(
|
||||
'SELECT *, 1 AS movie, custom.lastmod AS lastmod FROM rt_' +
|
||||
config.domain.replace(/[^a-z0-9]/g, '_') +
|
||||
config.database.all_movies.replace(/[^a-z0-9]/gi, '_') +
|
||||
' WHERE ' +
|
||||
Object.keys(Object.assign(query, { movie: '1' }))
|
||||
.map(function(key) {
|
||||
|
|
Loading…
Reference in New Issue