You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
350 B

import { createClient } from 'redis';
const connectRedis = async ()=>{
const redis = createClient({
password: process.env.REDIS_PWD,
socket: {
host: 'redis-11789.c329.us-east4-1.gce.redns.redis-cloud.com',
port: 11789
}
});
await redis.connect();
console.log('connected to redis');
return redis
}
export default await connectRedis()