mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-12-22 19:01:32 +00:00
Fix startup errors, add ci check (fixes #5209)
This commit is contained in:
parent
8d91543a13
commit
323b154e0b
2 changed files with 30 additions and 19 deletions
|
@ -178,7 +178,18 @@ steps:
|
|||
CARGO_HOME: .cargo_home
|
||||
commands:
|
||||
- cargo build
|
||||
- mv target/debug/lemmy_server target/lemmy_server
|
||||
- cp target/debug/lemmy_server target/lemmy_server
|
||||
when: *slow_check_paths
|
||||
|
||||
startup_errors:
|
||||
image: *rust_image
|
||||
environment:
|
||||
LEMMY_DATABASE_URL: postgres://lemmy:password@database:5432/lemmy
|
||||
CARGO_HOME: .cargo_home
|
||||
commands:
|
||||
- timeout --preserve-status 30 cargo run > lemmy.log 2>&1
|
||||
- cat lemmy.log
|
||||
- "! grep ERROR lemmy.log"
|
||||
when: *slow_check_paths
|
||||
|
||||
check_diesel_migration:
|
||||
|
|
|
@ -186,26 +186,26 @@ BEGIN
|
|||
AND pe.bot_account = FALSE
|
||||
UNION
|
||||
SELECT
|
||||
pl.person_id,
|
||||
pa.person_id,
|
||||
p.community_id
|
||||
FROM
|
||||
post_like pl
|
||||
INNER JOIN post p ON pl.post_id = p.id
|
||||
INNER JOIN person pe ON pl.person_id = pe.id
|
||||
post_actions pa
|
||||
INNER JOIN post p ON pa.post_id = p.id
|
||||
INNER JOIN person pe ON pa.person_id = pe.id
|
||||
WHERE
|
||||
pl.published > ('now'::timestamp - i::interval)
|
||||
pa.liked > ('now'::timestamp - i::interval)
|
||||
AND pe.bot_account = FALSE
|
||||
UNION
|
||||
SELECT
|
||||
cl.person_id,
|
||||
ca.person_id,
|
||||
p.community_id
|
||||
FROM
|
||||
comment_like cl
|
||||
INNER JOIN comment c ON cl.comment_id = c.id
|
||||
comment_actions ca
|
||||
INNER JOIN comment c ON ca.comment_id = c.id
|
||||
INNER JOIN post p ON c.post_id = p.id
|
||||
INNER JOIN person pe ON cl.person_id = pe.id
|
||||
INNER JOIN person pe ON ca.person_id = pe.id
|
||||
WHERE
|
||||
cl.published > ('now'::timestamp - i::interval)
|
||||
ca.liked > ('now'::timestamp - i::interval)
|
||||
AND pe.bot_account = FALSE) a
|
||||
GROUP BY
|
||||
community_id;
|
||||
|
@ -244,22 +244,22 @@ BEGIN
|
|||
AND pe.bot_account = FALSE
|
||||
UNION
|
||||
SELECT
|
||||
pl.person_id
|
||||
pa.person_id
|
||||
FROM
|
||||
post_like pl
|
||||
INNER JOIN person pe ON pl.person_id = pe.id
|
||||
post_actions pa
|
||||
INNER JOIN person pe ON pa.person_id = pe.id
|
||||
WHERE
|
||||
pl.published > ('now'::timestamp - i::interval)
|
||||
pa.liked > ('now'::timestamp - i::interval)
|
||||
AND pe.local = TRUE
|
||||
AND pe.bot_account = FALSE
|
||||
UNION
|
||||
SELECT
|
||||
cl.person_id
|
||||
ca.person_id
|
||||
FROM
|
||||
comment_like cl
|
||||
INNER JOIN person pe ON cl.person_id = pe.id
|
||||
comment_actions ca
|
||||
INNER JOIN person pe ON ca.person_id = pe.id
|
||||
WHERE
|
||||
cl.published > ('now'::timestamp - i::interval)
|
||||
ca.liked > ('now'::timestamp - i::interval)
|
||||
AND pe.local = TRUE
|
||||
AND pe.bot_account = FALSE) a;
|
||||
RETURN count_;
|
||||
|
|
Loading…
Reference in a new issue