1. AWS RDS PostgreSQL 에러 조치

// configs/typeorm.config.ts

export const typeORMConfig: TypeOrmModuleOptions = {
  type: 'postgres',
  host: 'postgres.cmgdorqgjahk.ap-northeast-2.rds.amazonaws.com',
  port: 5432,
  username: 'root',
  password: 'amskd135!',
  database: 'postgres',
  entities: [__dirname + '/../**/*.entity.{js.ts}'],
  synchronize: true,
};

1. 문제점

[Nest] 16964 - 2023. 07. 31. 오전 1:15:09 ERROR [TypeOrmModule] Unable to connect to the database. Retrying (2)... error: no pg_hba.conf entry for host "1.227.114.115", user "root", database "postgres", no encryption

Mysql에서는 잘 연결되었지만, postgreSQL은 연결이 되지 않는 에러 발견

2. 내가 해본 시도

  1. RDS 인바운드 규칙 설정

IP 설정을 1.227.114.115 추가하였지만 Fail

  1. postgreSQL Window Download 후 환경 변수 설정

Fail

  1. C드라이브에서 pg_hba.conf 확인

확인 시 0.0.0.0:/0 으로 설정 확인

  1. pgAdmin 재설치

→ 효과 없음