Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
services:
redis:
image: redis:7-alpine
container_name: momogo-redis
ports:
- "6379:6379"

kafka:
image: apache/kafka:3.8.0
container_name: momogo-kafka
ports:
- "9092:9092"
environment:
KAFKA_NODE_ID: 1
KAFKA_PROCESS_ROLES: broker,controller
KAFKA_LISTENERS: PLAINTEXT://:9092,CONTROLLER://:9093
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://localhost:9092
Comment on lines +16 to +17

@coderabbitai coderabbitai Bot Jul 31, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

[중대] 컨테이너용 Kafka 리스너를 분리하세요.

KAFKA_ADVERTISED_LISTENERSlocalhost:9092만 반환합니다. Kafka UI는 메타데이터를 받은 뒤 자기 컨테이너의 localhost:9092에 연결합니다. 따라서 Kafka UI가 브로커에 연결하지 못합니다.

호스트용 리스너와 Docker 네트워크용 리스너를 분리하세요. Kafka UI는 내부 리스너를 사용해야 합니다.

수정 예시
-      KAFKA_LISTENERS: PLAINTEXT://:9092,CONTROLLER://:9093
-      KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://localhost:9092
+      KAFKA_LISTENERS: HOST://:9092,INTERNAL://:29092,CONTROLLER://:9093
+      KAFKA_ADVERTISED_LISTENERS: HOST://localhost:9092,INTERNAL://kafka:29092
       KAFKA_CONTROLLER_LISTENER_NAMES: CONTROLLER
       KAFKA_CONTROLLER_QUORUM_VOTERS: 1@kafka:9093
-      KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: CONTROLLER:PLAINTEXT,PLAINTEXT:PLAINTEXT
-      KAFKA_INTER_BROKER_LISTENER_NAME: PLAINTEXT
+      KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: CONTROLLER:PLAINTEXT,HOST:PLAINTEXT,INTERNAL:PLAINTEXT
+      KAFKA_INTER_BROKER_LISTENER_NAME: INTERNAL
...
-      KAFKA_CLUSTERS_0_BOOTSTRAPSERVERS: kafka:9092
+      KAFKA_CLUSTERS_0_BOOTSTRAPSERVERS: kafka:29092
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docker-compose.yml` around lines 16 - 17, Update the Kafka listener
configuration in docker-compose.yml to separate host and Docker-network
endpoints: retain a localhost listener for host clients and add an internal
broker listener advertised with the Kafka service hostname. Configure Kafka UI
to use the internal listener rather than localhost, and keep KAFKA_LISTENERS
aligned with both advertised endpoints.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

현재 보일러 플레이트용 구성을 한 상태입니다. 추후 kafka 리스너를 구현하고 적용하면서 수정하도록 하겠습니다.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SungHuii, 확인했습니다. 현재 PR의 보일러플레이트 범위에서는 이 항목을 보류하겠습니다.

Kafka 리스너를 적용하는 작업 시점에는 호스트용 엔드포인트와 Docker 네트워크용 엔드포인트를 분리해야 합니다. 그렇지 않으면 Kafka UI와 같은 컨테이너 클라이언트가 localhost:9092로 연결을 시도할 수 있습니다.

이 작업을 추적할 GitHub 후속 이슈를 생성할까요?

🐇

You are interacting with an AI system.

KAFKA_CONTROLLER_LISTENER_NAMES: CONTROLLER
KAFKA_CONTROLLER_QUORUM_VOTERS: 1@kafka:9093
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: CONTROLLER:PLAINTEXT,PLAINTEXT:PLAINTEXT
KAFKA_INTER_BROKER_LISTENER_NAME: PLAINTEXT
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1

kafka-ui:
image: provectuslabs/kafka-ui:latest
container_name: momogo-kafka-ui
ports:
- "8090:8080"
environment:
KAFKA_CLUSTERS_0_NAME: local
KAFKA_CLUSTERS_0_BOOTSTRAPSERVERS: kafka:9092
depends_on:
- kafka
8 changes: 4 additions & 4 deletions k6/problem-ai/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import { check } from 'k6'; // 응답 결과(200 OK 등) 성공 여부 검증
* ============================================================================
*/

// 1. [서버 주소] 현재 배포된 AWS ALB(로드밸런서) 퍼블릭 DNS 주소
export const BASE_URL = 'http://momogo-alb-1906718718.ap-northeast-2.elb.amazonaws.com';
// 1. [서버 주소] EC2 + Nginx (momogo.kro.kr)
export const BASE_URL = 'http://momogo.kro.kr';
Comment on lines +16 to +17

@coderabbitai coderabbitai Bot Jul 31, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

[심각] 인증 요청에 HTTPS를 사용하세요.

load-test.js의 요청은 Authorization, X-XSRF-TOKEN, Cookie 헤더를 전송합니다. 현재 공개 HTTP 주소를 사용하므로 네트워크 구간에서 인증 정보가 노출될 수 있습니다.

유효한 인증서가 설정된 HTTPS 주소를 사용하세요.

🔐 변경 예시
-export const BASE_URL = 'http://momogo.kro.kr';
+export const BASE_URL = 'https://momogo.kro.kr';
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
// 1. [서버 주소] EC2 + Nginx (momogo.kro.kr)
export const BASE_URL = 'http://momogo.kro.kr';
// 1. [서버 주소] EC2 + Nginx (momogo.kro.kr)
export const BASE_URL = 'https://momogo.kro.kr';
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@k6/problem-ai/config.js` around lines 16 - 17, Update the BASE_URL
configuration to use the valid certificate-backed HTTPS endpoint instead of the
public HTTP address, ensuring load-test.js sends Authorization, X-XSRF-TOKEN,
and Cookie headers only over HTTPS.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이 부분은 아직 HTTPS 설정이 되어있지 않습니다. 추후 HTTPS를 구성한 후 해결하도록 하겠습니다.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SungHuii, 확인했습니다. HTTPS 설정은 별도 작업으로 진행해 주세요. 인프라 구성이 끝나면 BASE_URL 값을 https://momogo.kro.kr로 변경해 주세요. 이 항목은 나중에 처리하는 것으로 남겨두겠습니다.

(๑•̀ㅁ•́๑) 응원합니다, 화이팅!

You are interacting with an AI system.


// 2. [테스트 계정] ADMIN 권한 + 공간(Space) 소유 계정
export const ADMIN_USER = {
Expand All @@ -23,8 +23,8 @@ export const ADMIN_USER = {
};

// 3. [테스트 대상] ADMIN_USER 소유 공간/카테고리 UUID
export const SPACE_ID = '9d683a9a-9e5d-4a7c-9230-b40f7c62d31e';
export const CATEGORY_ID = 'effa0724-42c5-4335-964c-1e2556007e1a';
export const SPACE_ID = '07ddf318-4762-45b4-84e6-ec6be69d4f14';
export const CATEGORY_ID = 'e52067a1-8e66-4ec9-a343-927405c3b69d';

/**
* [JWT 인증 토큰 발급 setup 함수]
Expand Down
166 changes: 0 additions & 166 deletions k6/problem-ai/load-result.json

This file was deleted.

166 changes: 0 additions & 166 deletions k6/problem-ai/soak-result.json

This file was deleted.

Loading