Repository navigation
feat: Makefile で一括起動コマンド (make start-all) を追加 - #39
Conversation
- make start-all: ローカル環境を一括起動 - Docker の起動状態を自動確認 - Keycloak を起動 - Keycloak の自動セットアップスクリプトを実行 - .env.local の存在確認と自動作成 - make stop-all: ローカル環境を一括停止 - make restart-all: ローカル環境を再起動 - make setup-keycloak: Keycloak のみセットアップ - make check-docker: Docker 起動確認 - make help: ヘルプメッセージを拡張 Quick Start Guide を更新: - Makefile による一括起動手順を追記(推奨方法) - 手動セットアップ手順の見出しレベルを調整 README.md を更新: - クイックスタートセクションを追加 - Makefile コマンド一覧を追加 - Quick Start Guide へのリンク追加 これで `make start-all` 一発でローカル環境を起動できます。 Refs: Plan.md "NextAuth.js + Keycloak 認証統合 - 2025-11-13" 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
|
Caution Review failedThe pull request is closed. WalkthroughAdded Makefile targets to orchestrate Docker/Keycloak lifecycle ( Changes
Sequence Diagram(s)sequenceDiagram
participant Dev as Developer
participant Make as Makefile
participant Docker as Docker / Keycloak
participant Setup as setup-keycloak
participant UI as Control Plane UI
Dev->>Make: make start-all
Make->>Docker: check-docker (validate Docker & daemon)
Docker-->>Make: OK / error
Make->>Docker: docker compose up -d keycloak
Docker-->>Make: Keycloak starting
Make->>Setup: setup-keycloak
Setup->>Docker: wait for Keycloak readiness
Docker-->>Setup: ready
Setup->>Docker: run Keycloak setup script (realm/client/users)
Docker-->>Setup: setup complete
Make->>UI: create `.env.local` (from env.example) / show guidance
Make-->>Dev: environment ready
Dev->>UI: bun run dev
UI-->>Dev: app at http://localhost:3000
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Possibly related PRs
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
- README.md: 文末の句点を追加し、コロン表現を自然な日本語に修正 - docs/QUICKSTART.md: 文末の句点を追加し、コロン表現を自然な日本語に修正 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
There was a problem hiding this comment.
Actionable comments posted: 4
🧹 Nitpick comments (2)
Makefile (2)
38-51: Extract duplicated health check logic into a helper target or function.The Keycloak readiness wait logic (lines 42–49) is duplicated identically in the
start-alltarget (lines 61–68). Extract this into a reusable helper target to reduce duplication and ease future maintenance.For example, create a helper target:
+wait-keycloak-ready: + @echo "⏳ Keycloak の起動を待っています(最大60秒)..." + @bash -c 'for i in {1..30}; do \ + if curl -s -f http://localhost:8080/health/ready > /dev/null 2>&1; then \ + echo "✅ Keycloak が起動しました"; \ + break; \ + fi; \ + echo " 試行 $$i/30..."; \ + sleep 2; \ + done' + setup-keycloak: check-docker @echo "🚀 Keycloak をセットアップしています..." @cd infrastructure/docker/keycloak && docker compose up -d - @echo "⏳ Keycloak の起動を待っています(最大60秒)..." - @bash -c 'for i in {1..30}; do \ - if curl -s -f http://localhost:8080/health/ready > /dev/null 2>&1; then \ - echo "✅ Keycloak が起動しました"; \ - break; \ - fi; \ - echo " 試行 $$i/30..."; \ - sleep 2; \ - done' + $(MAKE) wait-keycloak-readyThen reference it in
start-allas well.
1-1: Consider addingallas a phony target.Per checkmake, the
allphony target is a conventional entry point. Currently,.PHONYdeclares many targets but notall. If you intend forallto be an alias to a specific target (e.g.,all: start-all), add it to.PHONYand define the target. Otherwise, silently ignore this note.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
Makefile(2 hunks)README.md(1 hunks)docs/QUICKSTART.md(6 hunks)
🧰 Additional context used
🪛 checkmake (0.2.2)
Makefile
[warning] 1-1: Missing required phony target "all"
(minphony)
[warning] 116-116: Target body for "help" exceeds allowed length of 5 (38).
(maxbodylength)
🪛 GitHub Actions: ci
docs/QUICKSTART.md
[error] 20-20: textlint: 文末が'。'で終わっていません。 (ja-technical-writing/ja-no-mixed-period)
[error] 20-20: textlint-ja/ai-writing/no-ai-colon-continuation: 「これで以下が自動的に実行されます:」のような述語とコロンで終わるパターンは、自然な日本語表現を検討してください。
README.md
[error] 33-33: textlint: 文末が'。'で終わっていません。 (ja-technical-writing/ja-no-mixed-period)
[error] 33-33: textlint-ja/ai-writing/no-ai-colon-continuation: 「これで以下が自動的に実行されます:」のような述語とコロンで終わるパターンは、自然な日本語表現を検討してください。
[error] 39-39: textlint: 文末が'。'で終わっていません。 (ja-technical-writing/ja-no-mixed-period)
🪛 markdownlint-cli2 (0.18.1)
docs/QUICKSTART.md
65-65: Bare URL used
(MD034, no-bare-urls)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: claude-review
🔇 Additional comments (1)
Makefile (1)
71-71: Clarify the intent of error suppression on setup-keycloak.sh.The
|| trueon line 71 silently swallows any errors from the setup script. If the script should fail loudly on errors, remove|| true. If it's intentionally forgiving (e.g., setup may partially fail but startup should continue), document why in a comment for clarity to future maintainers.
| #### 3.1 管理コンソールにアクセス | ||
| ##### 3.1 管理コンソールにアクセス | ||
|
|
||
| ブラウザで http://localhost:8080 を開く。 |
There was a problem hiding this comment.
Wrap bare URL in markdown link syntax.
Line 65 has a bare URL that violates MD034. Wrap it in markdown link syntax:
-ブラウザで http://localhost:8080 を開く。
+ブラウザで [http://localhost:8080](http://localhost:8080) を開く。Alternatively, shorten to a descriptive link:
-ブラウザで http://localhost:8080 を開く。
+ブラウザで [Keycloak 管理コンソール](http://localhost:8080) を開く。📝 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.
| ブラウザで http://localhost:8080 を開く。 | |
| ブラウザで [http://localhost:8080](http://localhost:8080) を開く。 |
| ブラウザで http://localhost:8080 を開く。 | |
| ブラウザで [Keycloak 管理コンソール](http://localhost:8080) を開く。 |
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)
65-65: Bare URL used
(MD034, no-bare-urls)
🤖 Prompt for AI Agents
In docs/QUICKSTART.md around line 65, the bare URL "http://localhost:8080"
violates MD034; wrap it in Markdown link syntax or replace it with a descriptive
link. Update the line to use either an explicit link like
[http://localhost:8080](http://localhost:8080) or a descriptive form such as
[Open the app in your browser](http://localhost:8080) so the URL is not bare.
コードレビュー - PR #39
|
…s red team (#1708) The Disruptions (red team) tab was empty because the problems submodule was pinned to de6a8f5, which predates the sample Battle getting a real red team. Bump the pin to a7ac11e (TenkaCloudChallenge main), which brings in: - #38 hello-world-battle: a real, explained red team — "frontend-down" disruption (ssm-run-command stops nginx; ADR-029 auto-revert after 600s). This is what makes the Disruptions tab non-empty so organizers can actually test the feature. - #39 microservice-migration-battle: red-team explanation in the description. - #40 problem "check engine" validator; #41 teaser ASCII-diagram fix. Also update apps/participant-portal/src/plugins/props-builder.test.ts: it used hello-world-battle as a "no disruptions" example, which is no longer true — switch the empty-case example to a challenge and pin the sample's new public disruption. To see it live, redeploy the problem-deploy backend (the event-handler Lambda bundles the catalog). Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
概要
ローカル環境を一括で起動・管理できる Makefile コマンドを追加しました。
変更内容
Makefile の拡張
ドキュメント更新
使い方
# Docker Desktop を起動してから実行 make start-allこれだけで以下が自動的に実行されます:
テスト
参照
🤖 Generated with Claude Code
Co-Authored-By: Claude noreply@anthropic.com
Summary by CodeRabbit
New Features
Documentation