Skip to content

Commit

Permalink
refactor: add redis username
Browse files Browse the repository at this point in the history
Added username env variable within backend/worker-service/ipfs-service
  • Loading branch information
BEdev24 authored Sep 11, 2024
1 parent 565adb0 commit ea9bc40
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions backend/example.env
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ JWT_REFRESH_TOKEN_EXPIRES_IN=7d
# Redis
REDIS_HOST=cache
REDIS_PORT=6379
REDIS_USERNAME=redis
REDIS_PASSWORD=password

# AWS SES
Expand Down
1 change: 1 addition & 0 deletions backend/src/redis/client/redis-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export const redisClientFactory: FactoryProvider<Redis> = {
const redisInstance = new Redis({
host: configService.getOrThrow('REDIS_HOST'),
port: configService.getOrThrow('REDIS_PORT'),
username: configService.getOrThrow('REDIS_USERNAME'),
password: configService.getOrThrow('REDIS_PASSWORD'),
});

Expand Down
1 change: 1 addition & 0 deletions ipfs-service/example.env
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ IPNS_CONSTITUTION_KEY_NAME='some-key-name'
# Redis
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_USERNAME=redis
REDIS_PASSWORD=password

## DHT QUEUE ##
Expand Down
1 change: 1 addition & 0 deletions ipfs-service/src/bullmq/bullmq.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { ExpressAdapter } from "@bull-board/express";
connection: {
host: configService.getOrThrow("REDIS_HOST"),
port: configService.getOrThrow("REDIS_PORT"),
username: configService.getOrThrow("REDIS_USERNAME"),
password: configService.getOrThrow("REDIS_PASSWORD"),
},
}),
Expand Down
1 change: 1 addition & 0 deletions worker-service/example.env
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ DB_SYNC_POSTGRES_PASSWORD=password
# Redis
REDIS_HOST=cache
REDIS_PORT=6379
REDIS_USERNAME=redis
REDIS_PASSWORD=password

# PAGINATION
Expand Down
1 change: 1 addition & 0 deletions worker-service/src/bullmq/bullmq.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { ExpressAdapter } from '@bull-board/express';
connection: {
host: configService.getOrThrow('REDIS_HOST'),
port: configService.getOrThrow('REDIS_PORT'),
username: configService.getOrThrow('REDIS_USERNAME'),
password: configService.getOrThrow('REDIS_PASSWORD'),
},
}),
Expand Down

0 comments on commit ea9bc40

Please sign in to comment.