iceshrimp/packages/backend/check_connect.js
Masaya Suzuki 00e42db681 Check redis connection
---------

Co-authored-by: tamaina <tamaina@hotmail.co.jp>
2023-02-23 22:04:47 -08:00

10 lines
269 B
JavaScript

import {loadConfig} from './built/config.js';
import {createRedisConnection} from "./built/redis.js";
const config = loadConfig();
const redis = createRedisConnection(config);
redis.on('connect', () => redis.disconnect());
redis.on('error', (e) => {
throw e;
});