Upgrade to Pro — share decks privately, control downloads, hide ads and more …

[JAWS-UG 京都] CDK with Amazon Q Developer

Avatar for Kyosuke Konishi Kyosuke Konishi
August 05, 2025
43

[JAWS-UG 京都] CDK with Amazon Q Developer

2025年 8月 2日に実施された JAWS-UG 京都で実施した CDK with Amazon Q Developer セッションの資料

Avatar for Kyosuke Konishi

Kyosuke Konishi

August 05, 2025
Tweet

Transcript

  1. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. CDK with Amazon Q Developer ハンズオン • Amazon Web Services Japan • Solutions Architect 小西 杏典(konippi) JAWS-UG 京都 CDK を基礎から学び AI で魔改造!? IaC を完全に理解する勉強会
  2. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 自己紹介 2 ⼩⻄ 杏典(Konishi Kyosuke) Amazon Web Services Japan Solutions Architect • 好きなサービス Amazon Q AWS CDK • 好きな OSS § aws/amazon-q-developer-cli (Amazon Q Developer CLI) 実は… 茶畑に囲まれた 宇治市 で生まれ育ちました
  3. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. • Amazon Q Developer についてと最新アップデート (10 min) • CDK with Amazon Q Developer CLI ハンズオン (50 min) Agenda 3
  4. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. Amazon Q Developerについて 4
  5. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 5 Amazon Q Developer Amazon Q はセキュリティとプライバシーを最初から考慮して構築されており、 組織が⽣成 AI を安全に利⽤できるようにします 開発者と IT 専⾨家がソフトウェア開発ライフサイクル (SDLC)全体を通してより迅速に構築できるよう⽀援 精度の⾼いコーディング推奨事項を提供 エージェントが⾃律的に機能実装、コードリファクタリン グ、ソフトウェアアップグレードなどを⽀援 Amazon Q は AWS の専⾨家であり、AWS 環境の最適化に 精通 最⾼⽔準のセキュリティ脆弱性スキャンと修復機能を提供
  6. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 6 SDLC において 開発者はどこに 時間を費やして いるか︖ レビュー・デプロイ 調査・計画 実装 保守・最新化 ・変換 テスト・ セキュリティ
  7. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. Software Development Life Cycle (SDLC) 全体を通して より迅速に構築 7 • 新規プロジェクト へより迅速に参加 • 新機能の計画⽴案 • AWS API の使⽤⽅ 法の理解 • 社内コードベース に関する質問 調査・計画 レビュー・ デプロイ • コードレビュー の⾃動化 • デプロイリスク の評価 • ドキュメントの ⽣成 実装 • IDE と CLI での 対話型コーディ ングアシスタン ト • ソフトウェア開 発 • 対話型コーディ ング テスト・ セキュリティ • ユニットテスト⽣ 成によるテスト カバレッジの向上 • セキュリティ脆弱 性のスキャンと修 復
  8. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 8 作業場所を問わず利⽤可能 AWS コンソール IDEs CLI Slack and Teams AWS コンソール モバイルアプリ GitLab Duo with Amazon Q AWS ドキュメント Amazon Q in GitHub I n P r e v i e w
  9. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 9 Amazon Q Developer IDE / CLI の機能 概要 IDE CLI Inline Chat コードを選択して変更 /dev Agentic Remote ⾃律的な機能開発とテスト /test /doc テストとドキュメント⽣成 /review セキュリティと品質のレビュー chat Local Agentic ⾃律的な機能開発とテスト translate ⾃然⾔語からコマンド⽣成 autocomplete AI ベースの⾃動コマンド補完 Inline Suggestions AI ベースの⾃動コード提案 Customize Amazon Q Developer IDE / CLI ともに ⽇本語をサポート Local Agentic Chat Workspace コードについてチャット Customize ⾃律的な機能開発とテスト ※ 2025/6/18 現在 / ⼀部抜粋
  10. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 10 Amazon Q Developer IDE / CLI 動作環境 Amazon Q Developer IDE / CLI ともに ⽇本語をサポート IDE CLI シェル: bash, zsh, fish OS: macOS, Linux ※1 ターミナルエミュレータ: iTerm2, macOS ターミナル, Hyper, Alacritty, Kitty, WezTerm , GnomeConsole, GnomeTerminal, Tilix, Terminator VS Code Terminal, Jetbrains terminal Eclipse IDEs JetBrains IDEs Visual Studio Code Visual Studio ※1 対応する Linux ディストリビューションはドキュメント参照 Windows も WSL では動作可能 https://docs.aws.amazon.com/ja_jp/amazonq/latest/qdeveloper-ug/command-line-supported-envs.html IDE ごとのサポート機能はドキュメントを参照 https://docs.aws.amazon.com/ja_jp/amazonq/latest/qdeveloper-ug/q-in-IDE.html
  11. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. Amazon Q Developer 最新アップデート 11
  12. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 以下で多言語サポート (日本語含む) を拡大 • AWS Managemant Console • AWS Console Mobile アプリケーション • Microsoft Teams • Slack チャットアプリケーション Jul 31 - 多言語サポートを拡大 12 https://aws.amazon.com/about-aws/whats-new/2025/07/q-developer-multi-language-support/ N E W
  13. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. • 特定のタスクに特化したエージェントの作成 • きめ細かいツール制御とセキュリティ管理 • 柔軟なコンテキスト管理と共有 Jul 31 - Amazon Q Developer CLI にエージェントを カスタマイズ可能な Custom Agents が登場 13 https://aws.amazon.com/about-aws/whats-new/2025/07/q-developer-multi-language-support/ N E W
  14. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. CDK with Amazon Q Developer CLI Hands-on 14
  15. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 【事前準備】 • AWS Builder ID or AWS IAM Identity Center でアカウントを用意 【Amazon Q Developer CLI にログイン】 1. q login コマンドでログイン 環境構築 (1/2) 15 AWS Builder ID の場合 AWS IAM Identity Centerの場合
  16. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 環境構築 (2/2) 16 ① ② ③
  17. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. ハンズオン資料 18 【事前準備】 • 「基礎から学ぶCDKハンズオン」で作成したスタック https://github.com/Konippi/cdk-with-q-dev-cli
  18. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 注意 19 • Amazon Q Developer Free Tier:無料 • Amazon Q Developer CLI によってデプロイされた AWS リソース:コストかかる
  19. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. ハンズオン内容 20 1. 現在の CDK 構成をドキュメント化 2. プロジェクトルールを作成 3. 現在の CDK 構成に API Gateway を追加してデプロイ 4. ユニットテストを追加
  20. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. ハンズオン完了イメージ 21 AWS Cloud AWS Lambda Amazon DynamoDB Amazon API Gateway AWS Cloud AWS Lambda Amazon DynamoDB
  21. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 23 MCP (Model Context Protocol) MCP は 基盤モデルを利用した複雑なエージェントやワークフローの実現を 支援するための オープンなプロトコル仕様 (※Anthropic社 が 提唱・策定) 特徴 • AIアプリケーションにおける統合の 複雑さを解決するためにAnthropic社が策 定したオープンなプロトコル • JSON-RPC 2.0を ワイヤプロトコル として採用 • Client-Server型アーキテクチャ • ホストアプリがツールやデータセットを 横断的に切替え、自律的な動作が可能に • バージョン 2025-03-26 でより実用的に 進化 (例:Streamable HTTP や OAuth2.1認証の仕様化 など) https://modelcontextprotocol.io/ ローカルPC や サーバー リモートサービス リモートMCPサービス Hostアプリケーション with MCP Client (IDEs, Tools, …) MCP Server A MCP Server B MCP Server C MCP MCP MCP ローカル リソース Web APIs リソース 基盤モデル
  22. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 24 補足:MCP のメリット (ユーザー側) MCPがあることで AIアプリケーション と 多様なクライアント とが 統一的なインターフェースで接続できる 引用元:https://norahsakal.com/blog/mcp-vs-api-model-context-protocol-explained/ MCPは "AIアプリケー ションにおけるUSB-C" に喩えられる
  23. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. 追加課題 25 1. AWS MCP Server を設定 2. CDK Nag による検査を追加 3. CDK Nag のエラーが出来るだけ少なくする (Suppression 多用は禁止)
  24. © 2025, Amazon Web Services, Inc. or its affiliates. All

    rights reserved. Thank you! • Kyosuke Konishi (konippi) @_konippi https://x.com/_konippi Konippi https://github.com/Konippi