mirror of
https://github.com/LemmyNet/lemmy.git
synced 2025-02-03 07:41:39 +00:00
fix health check
This commit is contained in:
parent
2be56b7373
commit
47638ccddd
2 changed files with 4 additions and 4 deletions
|
@ -41,8 +41,8 @@ afterAll(async () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
test("Upload image and delete it", async () => {
|
test("Upload image and delete it", async () => {
|
||||||
const healthz = await fetch(alphaUrl + "/pictrs/healthz");
|
const health = await alpha.imageHealth();
|
||||||
expect(healthz.status).toBe(200);
|
expect(health.success).toBeTruthy();
|
||||||
|
|
||||||
// Before running this test, you need to delete all previous images in the DB
|
// Before running this test, you need to delete all previous images in the DB
|
||||||
await deleteAllImages(alpha);
|
await deleteAllImages(alpha);
|
||||||
|
|
|
@ -428,8 +428,8 @@ pub fn config(cfg: &mut ServiceConfig, rate_limit: &RateLimitCell) {
|
||||||
.route(delete().to(delete_image)),
|
.route(delete().to(delete_image)),
|
||||||
)
|
)
|
||||||
.route("/proxy", get().to(image_proxy))
|
.route("/proxy", get().to(image_proxy))
|
||||||
.route("/{filename}", get().to(get_image))
|
.route("/health", get().to(pictrs_health))
|
||||||
.route("/health", get().to(pictrs_health)),
|
.route("/{filename}", get().to(get_image)),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue