Download free for 30 days
Sign in
Upload
Language (EN)
Support
Business
Mobile
Social Media
Marketing
Technology
Art & Photos
Career
Design
Education
Presentations & Public Speaking
Government & Nonprofit
Healthcare
Internet
Law
Leadership & Management
Automotive
Engineering
Software
Recruiting & HR
Retail
Sales
Services
Science
Small Business & Entrepreneurship
Food
Environment
Economy & Finance
Data & Analytics
Investor Relations
Sports
Spiritual
News & Politics
Travel
Self Improvement
Real Estate
Entertainment & Humor
Health & Medicine
Devices & Hardware
Lifestyle
Change Language
Language
English
Español
Português
Français
Deutsche
Cancel
Save
Submit search
EN
Uploaded by
Amazon Web Services Japan
19,436 views
20201125 AWS Black Belt Online Seminar AWS CodeBuild
AWS 公式オンラインセミナー: https://amzn.to/JPWebinar 過去資料: https://amzn.to/JPArchive
Technology
◦
Read more
4
Save
Share
Embed
Embed presentation
1
/ 72
2
/ 72
3
/ 72
4
/ 72
5
/ 72
6
/ 72
7
/ 72
8
/ 72
9
/ 72
10
/ 72
11
/ 72
12
/ 72
13
/ 72
14
/ 72
15
/ 72
Most read
16
/ 72
17
/ 72
18
/ 72
19
/ 72
20
/ 72
21
/ 72
22
/ 72
23
/ 72
24
/ 72
25
/ 72
26
/ 72
27
/ 72
28
/ 72
29
/ 72
30
/ 72
31
/ 72
Most read
32
/ 72
33
/ 72
34
/ 72
35
/ 72
36
/ 72
37
/ 72
38
/ 72
39
/ 72
40
/ 72
41
/ 72
42
/ 72
43
/ 72
44
/ 72
45
/ 72
46
/ 72
47
/ 72
48
/ 72
49
/ 72
50
/ 72
51
/ 72
52
/ 72
53
/ 72
54
/ 72
55
/ 72
56
/ 72
57
/ 72
58
/ 72
59
/ 72
60
/ 72
61
/ 72
62
/ 72
63
/ 72
64
/ 72
65
/ 72
66
/ 72
67
/ 72
68
/ 72
Most read
69
/ 72
70
/ 72
71
/ 72
72
/ 72
More Related Content
PDF
202205 AWS Black Belt Online Seminar Amazon VPC IP Address Manager (IPAM)
by
Amazon Web Services Japan
PDF
202205 AWS Black Belt Online Seminar Amazon FSx for OpenZFS
by
Amazon Web Services Japan
PDF
202204 AWS Black Belt Online Seminar AWS IoT Device Defender
by
Amazon Web Services Japan
PDF
Infrastructure as Code (IaC) 談義 2022
by
Amazon Web Services Japan
PDF
202204 AWS Black Belt Online Seminar Amazon Connect を活用したオンコール対応の実現
by
Amazon Web Services Japan
PDF
202204 AWS Black Belt Online Seminar Amazon Connect Salesforce連携(第1回 CTI Adap...
by
Amazon Web Services Japan
PDF
Amazon Game Tech Night #25 ゲーム業界向け機械学習最新状況アップデート
by
Amazon Web Services Japan
PPTX
20220409 AWS BLEA 開発にあたって検討したこと
by
Amazon Web Services Japan
202205 AWS Black Belt Online Seminar Amazon VPC IP Address Manager (IPAM)
by
Amazon Web Services Japan
202205 AWS Black Belt Online Seminar Amazon FSx for OpenZFS
by
Amazon Web Services Japan
202204 AWS Black Belt Online Seminar AWS IoT Device Defender
by
Amazon Web Services Japan
Infrastructure as Code (IaC) 談義 2022
by
Amazon Web Services Japan
202204 AWS Black Belt Online Seminar Amazon Connect を活用したオンコール対応の実現
by
Amazon Web Services Japan
202204 AWS Black Belt Online Seminar Amazon Connect Salesforce連携(第1回 CTI Adap...
by
Amazon Web Services Japan
Amazon Game Tech Night #25 ゲーム業界向け機械学習最新状況アップデート
by
Amazon Web Services Japan
20220409 AWS BLEA 開発にあたって検討したこと
by
Amazon Web Services Japan
More from Amazon Web Services Japan
PDF
202202 AWS Black Belt Online Seminar AWS Managed Rules for AWS WAF の活用
by
Amazon Web Services Japan
PDF
202203 AWS Black Belt Online Seminar Amazon Connect Tasks.pdf
by
Amazon Web Services Japan
PDF
SaaS テナント毎のコストを把握するための「AWS Application Cost Profiler」のご紹介
by
Amazon Web Services Japan
PDF
Amazon QuickSight の組み込み方法をちょっぴりDD
by
Amazon Web Services Japan
PDF
マルチテナント化で知っておきたいデータベースのこと
by
Amazon Web Services Japan
PDF
機密データとSaaSは共存しうるのか!?セキュリティー重視のユーザー層を取り込む為のネットワーク通信のアプローチ
by
Amazon Web Services Japan
PDF
パッケージソフトウェアを簡単にSaaS化!?既存の資産を使ったSaaS化手法のご紹介
by
Amazon Web Services Japan
PDF
202202 AWS Black Belt Online Seminar Amazon Connect Customer Profiles
by
Amazon Web Services Japan
PDF
Amazon Game Tech Night #24 KPIダッシュボードを最速で用意するために
by
Amazon Web Services Japan
PDF
202202 AWS Black Belt Online Seminar AWS SaaS Boost で始めるSaaS開発⼊⾨
by
Amazon Web Services Japan
PPTX
[20220126] JAWS-UG 2022初頭までに葬ったAWSアンチパターン大紹介
by
Amazon Web Services Japan
PDF
202111 AWS Black Belt Online Seminar AWSで構築するSmart Mirrorのご紹介
by
Amazon Web Services Japan
PDF
202201 AWS Black Belt Online Seminar Apache Spark Performnace Tuning for AWS ...
by
Amazon Web Services Japan
PDF
202112 AWS Black Belt Online Seminar 店内の「今」をお届けする小売業向けリアルタイム配信基盤のレシピ
by
Amazon Web Services Japan
PDF
20211209 Ops-JAWS Re invent2021re-cap-cloud operations
by
Amazon Web Services Japan
PDF
20211203 AWS Black Belt Online Seminar AWS re:Invent 2021アップデート速報
by
Amazon Web Services Japan
PDF
[AWS EXpert Online for JAWS-UG 18] 見せてやるよ、Step Functions の本気ってやつをな
by
Amazon Web Services Japan
PPTX
20211109 JAWS-UG SRE keynotes
by
Amazon Web Services Japan
PPTX
20211109 bleaの使い方(基本編)
by
Amazon Web Services Japan
PDF
202110 AWS Black Belt Online Seminar AWS Site-to-Site VPN
by
Amazon Web Services Japan
202202 AWS Black Belt Online Seminar AWS Managed Rules for AWS WAF の活用
by
Amazon Web Services Japan
202203 AWS Black Belt Online Seminar Amazon Connect Tasks.pdf
by
Amazon Web Services Japan
SaaS テナント毎のコストを把握するための「AWS Application Cost Profiler」のご紹介
by
Amazon Web Services Japan
Amazon QuickSight の組み込み方法をちょっぴりDD
by
Amazon Web Services Japan
マルチテナント化で知っておきたいデータベースのこと
by
Amazon Web Services Japan
機密データとSaaSは共存しうるのか!?セキュリティー重視のユーザー層を取り込む為のネットワーク通信のアプローチ
by
Amazon Web Services Japan
パッケージソフトウェアを簡単にSaaS化!?既存の資産を使ったSaaS化手法のご紹介
by
Amazon Web Services Japan
202202 AWS Black Belt Online Seminar Amazon Connect Customer Profiles
by
Amazon Web Services Japan
Amazon Game Tech Night #24 KPIダッシュボードを最速で用意するために
by
Amazon Web Services Japan
202202 AWS Black Belt Online Seminar AWS SaaS Boost で始めるSaaS開発⼊⾨
by
Amazon Web Services Japan
[20220126] JAWS-UG 2022初頭までに葬ったAWSアンチパターン大紹介
by
Amazon Web Services Japan
202111 AWS Black Belt Online Seminar AWSで構築するSmart Mirrorのご紹介
by
Amazon Web Services Japan
202201 AWS Black Belt Online Seminar Apache Spark Performnace Tuning for AWS ...
by
Amazon Web Services Japan
202112 AWS Black Belt Online Seminar 店内の「今」をお届けする小売業向けリアルタイム配信基盤のレシピ
by
Amazon Web Services Japan
20211209 Ops-JAWS Re invent2021re-cap-cloud operations
by
Amazon Web Services Japan
20211203 AWS Black Belt Online Seminar AWS re:Invent 2021アップデート速報
by
Amazon Web Services Japan
[AWS EXpert Online for JAWS-UG 18] 見せてやるよ、Step Functions の本気ってやつをな
by
Amazon Web Services Japan
20211109 JAWS-UG SRE keynotes
by
Amazon Web Services Japan
20211109 bleaの使い方(基本編)
by
Amazon Web Services Japan
202110 AWS Black Belt Online Seminar AWS Site-to-Site VPN
by
Amazon Web Services Japan
Recently uploaded
PDF
SEO in Charleston SC | Local SEO Strategies to Grow Your Business.pdf
by
customdigitalsolutio1
PPTX
How Blockchain Application Development Enables Trustless Digital Ecosystems.pptx
by
Lisa ward
PDF
6 Insights from the Patron Saint of AI Failure
by
Scott M. Graffius
PDF
Effective Ai powered mock interview .pdf
by
amazingnishusingh766
PDF
TrustArc Webinar - Unpacking India’s DPDP Act: What You Should Know
by
TrustArc
PDF
Requestly or Postman: What’s the Right API Tool for Your Team?
by
henrycavill30521
PPTX
Building Real-Time Voice AI — Udaiappa Ramachandran
by
Udaiappa Ramachandran
PPTX
Design Flaws and Known Attacks in Agentic AI - ITI Business Session
by
Information Technology Institute
PDF
Chapter 2 Computer Threat .pdf
by
Getnet Tigabie Askale -(GM)
PDF
DataLiva-LivaGRC- Business Software for Governance, Risk, and Compliance
by
Mustafa Kuğu
PPTX
Oracle SCM Cloud Solutions for Smart Supply Chain Management
by
Chetu
PPTX
Software Tools for penetration Testing (1).pptx
by
AmosCheruiyot13
PPTX
DVCON24-IBM ai/ml driven hardware verification
by
Arun Joseph
PPTX
Unit 1 Introduction of Computer Networks
by
SuvarnaSharma5
PPTX
Lecture 05. API Security for DevSecOps Eng.pptx
by
vinocol222
PPTX
JAVA Programming Lecture 1 C 4 Yourself.pptx
by
yvsbglfaeahuyldzhq
PDF
Using Change Data Capture (CDC) to Ingest Data into Apache Kafka
by
Giovanni Marigi
PPTX
Full course that Prymehat uploads for you version 2
by
OhenebaManu1
PDF
Mobile Onboarding UX 11 Best Practices for Retention (2026).pdf
by
Design Studio UI UX
PDF
Governing Agentic Enterprise - From Shadow AI to Autonomous Security.pdf
by
sajjasridhar1990
SEO in Charleston SC | Local SEO Strategies to Grow Your Business.pdf
by
customdigitalsolutio1
How Blockchain Application Development Enables Trustless Digital Ecosystems.pptx
by
Lisa ward
6 Insights from the Patron Saint of AI Failure
by
Scott M. Graffius
Effective Ai powered mock interview .pdf
by
amazingnishusingh766
TrustArc Webinar - Unpacking India’s DPDP Act: What You Should Know
by
TrustArc
Requestly or Postman: What’s the Right API Tool for Your Team?
by
henrycavill30521
Building Real-Time Voice AI — Udaiappa Ramachandran
by
Udaiappa Ramachandran
Design Flaws and Known Attacks in Agentic AI - ITI Business Session
by
Information Technology Institute
Chapter 2 Computer Threat .pdf
by
Getnet Tigabie Askale -(GM)
DataLiva-LivaGRC- Business Software for Governance, Risk, and Compliance
by
Mustafa Kuğu
Oracle SCM Cloud Solutions for Smart Supply Chain Management
by
Chetu
Software Tools for penetration Testing (1).pptx
by
AmosCheruiyot13
DVCON24-IBM ai/ml driven hardware verification
by
Arun Joseph
Unit 1 Introduction of Computer Networks
by
SuvarnaSharma5
Lecture 05. API Security for DevSecOps Eng.pptx
by
vinocol222
JAVA Programming Lecture 1 C 4 Yourself.pptx
by
yvsbglfaeahuyldzhq
Using Change Data Capture (CDC) to Ingest Data into Apache Kafka
by
Giovanni Marigi
Full course that Prymehat uploads for you version 2
by
OhenebaManu1
Mobile Onboarding UX 11 Best Practices for Retention (2026).pdf
by
Design Studio UI UX
Governing Agentic Enterprise - From Shadow AI to Autonomous Security.pdf
by
sajjasridhar1990
20201125 AWS Black Belt Online Seminar AWS CodeBuild
1.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS 公式 Webinar https://amzn.to/JPWebinar 過去資料 https://amzn.to/JPArchive Solutions Architect 松本 雅博 2020/11/25 AWS CodeBuild サービスカットシリーズ [AWS Black Belt Online Seminar]
2.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 自己紹介 松本 雅博(まつもと まさひろ) 技術統括本部 西日本ソリューション部 ソリューションアーキテクト 関西を中心に、西日本のお客様をご支援 好きなサービス • Code シリーズ • AWS CloudFormation, AWS Cloud Development Kit
3.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS Black Belt Online Seminar とは 「サービス別」「ソリューション別」「業種別」のそれぞれのテーマに分かれて、アマゾ ン ウェブ サービス ジャパン株式会社が主催するオンラインセミナーシリーズです。 質問を投げることができます! • 書き込んだ質問は、主催者にしか見えません • 今後のロードマップに関するご質問は お答えできませんのでご了承下さい ① 吹き出しをクリック ② 質問を入力 ③ Sendをクリック Twitter ハッシュタグは以下をご利用ください #awsblackbelt
4.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 内容についての注意点 • 本資料では2020年11月25日現在のサービス内容および価格についてご説明しています。最新の 情報はAWS公式ウェブサイト(http://aws.amazon.com)にてご確認ください。 • 資料作成には十分注意しておりますが、資料内の価格とAWS公式ウェブサイト記載の価格に相 違があった場合、AWS公式ウェブサイトの価格を優先とさせていただきます。 • 価格は税抜表記となっています。日本居住者のお客様には別途消費税をご請求させていただきま す。 • AWS does not offer binding price quotes. AWS pricing is publicly available and is subject to change in accordance with the AWS Customer Agreement available at http://aws.amazon.com/agreement/. Any pricing information included in this document is provided only as an estimate of usage charges for AWS services based on certain information that you have provided. Monthly charges will be based on your actual use of AWS services, and may vary from the estimates provided.
5.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 本セミナーの概要 • 本セミナーで学習できること • AWS CodeBuild • 対象者 • アーキテクトの方 • 技術者の方
6.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 本日のアジェンダ • AWS CodeBuild 概要 • buildspec.yml について • 機能紹介 • まとめ
7.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ソフトウェア開発に関連する AWS サービス AWS CodeBuild + Third Party AWS CodeCommit AWS CodeBuild AWS CodeDeploy AWS X-Ray AWS CodePipeline MONITORDEPLOYTESTBUILD SOURCE / ARTIFACT AUTHOR AWS Cloud9 AWS IDE Toolkits Amazon CloudWatch AWS CloudFormation AWS SAMAWS Cloud Development KitMODEL Amazon CodeGuru AWS CodeArtifact
8.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ソフトウェア開発に関連する AWS サービス AWS CodeBuild + Third Party AWS CodeCommit AWS CodeBuild AWS CodeDeploy AWS X-Ray AWS CodePipeline MONITORDEPLOYTESTBUILD SOURCE / ARTIFACT AUTHOR AWS Cloud9 AWS IDE Toolkits Amazon CloudWatch AWS CloudFormation AWS SAMAWS Cloud Development KitMODEL Amazon CodeGuru AWS CodeArtifact
9.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild フルマネージドなビルドサービスでソースコードの コンパイル、テスト実行、ソフトウェア パッケージの作成を実行 継続的なスケールと同時複数ビルドプロセス サーバーの管理は不要 利用した分のみの支払い(分単位の課金) Amazon CloudWatch によるモニタリング可能
10.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild 一貫したイミュータブルな環境のために個々の ビルドを新規 Docker コンテナで実行 すべてのオフィシャルな AWS CodeBuild イメージ に Docker と AWS CLI をインストール済み ニーズに応じて Docker イメージを作成することに よってカスタムなビルド環境を提供可能
11.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild の実行方法 AWS Command Line Interface AWS Tools and SDKs AWS CodePipeline AWS CodeBuild AWS Management Console
12.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild の仕組み AWS Command Line Interface AWS Tools and SDKs AWS CodePipeline AWS CodeBuild AWS Management Console
13.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild の仕組み AWS Command Line Interface AWS Tools and SDKs AWS CodePipeline AWS CodeBuild AWS Management Console Amazon Simple Storage Service (S3) ソースコード ビルドプロジェクト ビルド環境 作成
14.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild の仕組み AWS Command Line Interface AWS Tools and SDKs AWS CodePipeline AWS CodeBuild AWS Management Console Amazon Simple Storage Service (S3) ソースコード ビルドプロジェクト ビルド環境 Amazon CloudWatch Amazon CloudWatch Logs 取得 メトリクス / ログ送信 メトリクス / ログ取得
15.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild の仕組み AWS Command Line Interface AWS Tools and SDKs AWS CodePipeline AWS CodeBuild AWS Management Console Amazon Simple Storage Service (S3) ビルドプロジェクト ビルド環境 アップロード
16.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild の仕組み AWS Command Line Interface AWS Tools and SDKs AWS CodePipeline AWS CodeBuild AWS Management Console ビルドプロジェクト ビルド環境 AWS ChatbotAmazon Simple Notification Service 通知
17.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成
18.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成 プロジェクト名を入力
19.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成 ソースとして Amazon S3 を選択し、 バケット名と オブジェクトキーを入力
20.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成 オペレーティングシステムに Amazon Linux 2 を選択し、 ランタイムとイメージを指定する
21.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成 ビルド仕様は buildspec ファイルを使用するを選択
22.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成 アーティファクトのタイプに Amazon S3 を選択し、 バケット名を入力する
23.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS CodeBuild プロジェクトの作成 CloudWatch Logs へログを送信する
24.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ソースの作成
25.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ソースの作成 buildspec のバージョン ランタイムに Java を指定 jar ファイルを作成 ビルド出力を定義
26.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ビルドの実行
27.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ビルドの実行
28.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 本日のアジェンダ • AWS CodeBuild 概要 • buildspec.yml について • 機能紹介 • まとめ
29.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. version: run-as: env: proxy: batch: phases: reports: artifacts: cache: buidspec.yml の構成 buildspec のバージョン コマンドを実行する Linux ユーザ 環境変数 プロキシサーバ設定 バッチビルド設定 実行するコマンド テストレポート作成 AWS CodeBuild の出力 キャッシュ設定
30.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. version: run-as: env: proxy: batch: phases: reports: artifacts: cache: buidspec.yml の構成 (必須)buildspec のバージョン コマンドを実行する Linux ユーザ 環境変数 プロキシサーバ設定 バッチビルド設定 (必須)実行するコマンド テストレポート作成 AWS CodeBuild の出力 キャッシュ設定
31.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. version • 0.2 の使用を推奨 • 0.1 も引き続き利用可能 • バージョン 0.2 での変更点 • environment_variables → env • plaintext → variables • artifacts の type プロパティ廃止 • 同一インスタンスで全てのビルドコマンドを実行 version: 0.2 buildspec のバージョン
32.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. version phases: build: commands: - SERVICE_NAME=CodeBuild - echo ${SERVICE_NAME} version: 0.2 の場合 Running command echo ${SERVICE_NAME} CodeBuild version: 0.1 の場合 Running command echo ${SERVICE_NAME} version 0.1 は各コマンドが独立して実行される
33.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. run-as • Linux 環境でのみ使用可能 • 指定したユーザに読み取りおよび実行権限を付与 • 指定しない場合、すべてのコマンドが root ユーザで実行される • Phases ブロックでオーバーライド可能 run-as: Linux-user-name phases: build: run-as: Linux-user-name-02 コマンドを実行する Linux ユーザ
34.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. env 環境変数 env: shell: shell-tag variables: key: "value" parameter-store: key: "value" exported-variables: - variable secrets-manager: key: secret-id:json-key:version-stage:version-id git-credential-helper: no | yes • 環境変数には以下を指定可能 • プレーンテキスト • AWS Systems Manager Parameter Store の値 • AWS Secrets Manager の値 • 利用するシェル • Bash, /bin/sh • Powershell.exe, cmd.exe • Git 認証ヘルパーを利用するか
35.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. proxy • アーティファクトのアップロード時、CloudWatch Logs への ログ送信時に プロキシサーバを利用するか個別に定義可能 • 明示的なプロキシサーバを利用する場合、環境変数の設定が必要 • HTTP_PROXY, HTTPS_PROXY, NO_PROXY proxy: upload-artifacts: no | yes logs: no | yes プロキシサーバ設定
36.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. batch • プロジェクトの同時実行と協調実行の定義を行う • バッチビルドには 3 つのタイプがある • build-graph • build-list • build-matrix バッチビルド設定 batch: fast-fail: false | true # build-list: # build-matrix: # build-graph:
37.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. batch/build-graph batch: fast-fail: false build-graph: - identifier: build1 env: compute-type: BUILD_GENERAL1_SMALL - identifier: build2 env: compute-type: BUILD_GENERAL1_MEDIUM depend-on: - build1 - identifier: build3 env: compute-type: BUILD_GENERAL1_LARGE depend-on: - build2 build1 build2 build3 ビルド開始 ビルド終了 バッチ内の他のタスクに依存する一連のタスクを定義
38.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. batch/build-list batch: fast-fail: false build-list: ignore-failure: true - identifier: linux_small env: compute-type: BUILD_GENERAL1_SMALL - identifier: windows_medium env: type: WINDOWS_SERVER_2019_CONTAINER image: aws/codebuild/windows-base:2019-1.0 compute-type: BUILD_GENERAL1_MEDIUM linux_small windows_medium ビルド開始 ビルド終了 同時に実行されるタスクを定義
39.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. batch/build-matrix batch: build-matrix: static: ignore-failure: false env: type: LINUX_CONTAINER privileged-mode: true dynamic: env: image: - aws/codebuild/amazonlinux2-x86_64-standard:3.0 - aws/codebuild/windows-base:2019-1.0 variables: MY_VAR: - VALUE1 - VALUE2 - VALUE3 amazonlinux2 MY_VAR=VALUE1 amazonlinux2 MY_VAR=VALUE2 amazonlinux2 MY_VAR=VALUE3 windows MY_VAR=VALUE1 windows MY_VAR=VALUE2 windows MY_VAR=VALUE3 ビルド開始 ビルド終了 さまざまな環境と並行して実行されるタスクを定義
40.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. phases: install: runtime-versions: runtime: version runtime: version pre_build: build: post_build: phases run-as: Linux-user-name commands: - command - command finally: - command - command install パッケージのインストールのみに利用することを推奨 runtime-versions でランタイムを指定可能 pre_build ビルド前に実行するコマンドを記述 Amazon ECR へのサイインイン、npm の依存関係インストールなど build ビルド中に実行するコマンドを記述 post_build ビルド後に実行するコマンドを記述 ビルドアーティファクトを jar, war にする, Docker イメージを Amazon ECR へ Push など ビルドの各段階で CodeBuild が実行するコマンド記述する
41.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. reports • テストレポート とコードカバレッジレポートの2種類 テストレポート の作成 reports: report-group-name-or-arn: files: - location - location base-directory: location discard-paths: no | yes file-format: report-format
42.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. reports • 以下のフォーマットに対応 • Cucumber JSON, JUnitXML, NUnitXML, NUnit3 XML, TestNGXML, Visual Studio TRX テストレポート ( JunitXMLの 例 ) reports: junit-report: files: - 'target/surefire-reports/TEST-TestMessageUtil.xml' file-format: JUNITXML
43.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. reports テストレポート
44.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. reports コードカバレッジレポート ( JaCoCoXML の例 ) reports: jacoco-report: files: - 'target/site/jacoco/jacoco.xml' file-format: 'JACOCOXML' • 以下のフォーマットに対応 • Clover XML, Cobertula XML, JaCoCoXML, SimpleCovJSON
45.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. reports コードカバレッジレポート
46.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. reports コードカバレッジレポート • ラインカバレッジ ( C0 : 命令網羅率 ) • line coverage = (total lines covered)/(total number of lines) • コードのうち、テストで実行された行の割合 • ブランチカバレッジ ( C1 : 分岐網羅率 ) • branch coverage = (total branches covered)/(total number of branches) • 分岐のうち、テストで実行された分岐の割合
47.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. artifacts • アーティファクトの名、アーティファクトに 含めるサブディレクトリとファイルを指定 • secondary-artifacts を利用して、複数のビルド 出力アーティファクトを定義することも可能 CodeBuild の出力を定義 artifacts: files: - location name: artifact-name discard-paths: no | yes base-directory: location secondary-artifacts: artifactIdentifier: files: - location name: secondary-artifact-name discard-paths: no | yes base-directory: location
48.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. cache • キャッシュタイプはビルドプロジェクトに対して設定 • キャッシュなし、S3 、ローカル • S3 キャッシュと, ローカルキャッシュのカスタムキャッシュは buildspec でキャッシュ対象を指定する キャッシュの設定 cache: paths: - path - path
49.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. cache • S3 キャッシュでは個別のファイルを指定可能 S3 キャッシュの設定 cache: paths: - ${ディレクトリ} - ${ファイル}
50.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. cache • ローカルキャッシュのカスタムキャッシュは ディレクトリのみ指定可能 ローカル キャッシュの設定 cache: paths: - ${ディレクトリ}
51.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. cache • ソースキャッシュ • Git メタデータをキャッシュ • コミット間の変更のみが Pull される • Docker レイヤーキャッシュ • Docker レイヤーをキャッシュ • Linux 環境のみ使用可能 • カスタムキャッシュ • 上記に該当しない場合 • 個々のファイルは指定できず、ディレクトリのみ指定可能 ローカル キャッシュ
52.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 本日のアジェンダ • AWS CodeBuild 概要 • buildspec.yml について • 機能紹介 • まとめ
53.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ビルドをローカルで実行する git clone https://github.com/aws/aws-codebuild-docker-images.git cd aws-codebuild-docker-images/ubuntu/standard/4.0 docker build -t aws/codebuild/standard:4.0 . docker pull amazon/aws-codebuild-local:latest --disable-content-trust=false ビルドイメージの設定 docker pull amazon/aws-codebuild-local:latest --disable-content-trust=false wget https://raw.githubusercontent.com/aws/aws-codebuild-docker-images/master/local_builds/codebuild_build.sh chmod +x codebuild_build.sh CodeBuild エージェントのイメージとスクリプトを取得 AWS CodeBuild エージェントを使用して、ローカルマシンでビルド可能 • Git と Docker が必要
54.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. • スクリプトはビルドイメージを起動し、カレントディレクトリにあるプロ ジェクトでビルドを実行する • ビルドプロジェクトの場所を指定するには -s オプションを利用する • 出力ディレクトリの指定には –a オプションを利用する ビルドをローカルで実行する ./codebuild_build.sh -i aws/codebuild/standard:4.0 -a <output directory> カレントディレクトリのプロジェクトでビルド ./codebuild_build.sh -i aws/codebuild/standard:4.0 –s <build project directory> -a <output directory> プロジェクトの場所を指定してビルド AWS CodeBuild エージェントを使用して、ローカルマシンでビルド可能
55.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS Session Manager でビルド環境へアクセスする • buildspec.yml に codebuild-breakpoint を埋め込み、 ビルド設定でセッション接続を有効にする • Session Manager でビルド環境にアクセスし、調査を実施 • ビルドを再開するには codebuild-resume を実行する マネジメントコンソール、CLI を介して Linux, Windows のビルド環境にアクセス
56.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS Session Manager でビルド環境へアクセスする phases: install: runtime-versions: java: corretto11 pre_build: commands: - echo Nothing to do in the pre_build phase... build: commands: - echo Build started on `date` - mvn install post_build: commands: - echo Build completed on `date` - codebuild-breakpoint codebuild-breakpoint コマンドでブレイクポイントをセット
57.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS Session Manager でビルド環境へアクセスする
58.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. Session Manager でビルド環境へアクセスする チェックを入れると必要な権限が ロールに追加される
59.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. Session Manager でビルド環境へアクセスする
60.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. Session Manager でビルド環境へアクセスする
61.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. Session Manager でビルド環境へアクセスする codebuild-resume ビルドを再開する codebuild-resume コマンドでビルドを再開
62.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. • ビルドプロジェクに対して生成される パブリック可能な URL で認証不要 • CodeCommit や GitHub のマークダウン ファイルに埋め込み、ビルドステータスを 表示することが可能 ビルドバッジ 埋め込み可能なイメージ(バッジ)として動的に生成されるステータス画像
63.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. ステータスの通知 通知ルールを設定してビルド状況の通知を受けることが可能 Amazon Simple Notification Service AWS Chatbot
64.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. VPC 内リソースへのアクセス • プライベートサブネット内のリソースへアクセス • VPCエンドポイント経由でのみアクセスできるように設定されたサービス へのアクセス • 固定 IP アドレスを必要とする外部サービスへの通信に NAT ゲートウェイ, NAT インスタンスの EIP を使用する 注意点 • NAT ゲートウェイ、NAT インスタンスの代わりにインターネットゲート ウェイを利用することはできない
65.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. VPC エンドポイントをサポート • 連邦情報処理標準(FIPS) 準拠オプションもあり AWS Cloud VPC Private subnet Instance codebuild AWS CodeBuild
66.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 利用料金 インスタンスタイプ メモリ vCPU Linux ビルド(1分) Windows ビルド(1分) general1.small 3 GB 2 0.005USD 該当なし general1.medium 7 GB 4 0.01USD arm1.large 16 GiB 8 0.02USD general1.large 15 GB 8 0.02USD general1.2xlarge 144 GiB 72 0.25USD gpu1.large 244 GiB 32 0.90USD 料金(東京リージョン) 無料利用枠 general1.small 100 分(月) general1.small で、1 回 5 分 , 月に 300回 ビルドした場合 0.005USD * 5 分 * 300 回 = 7.5USD
67.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. 本日のアジェンダ • AWS CodeBuild 概要 • buildspec.yml について • 機能紹介 • まとめ
68.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. まとめ • AWS CodeBuild は、フルマネージドなビルドサービスでソースコー ドのコンパイル、テスト実行、ソフトウェアパッケージの作成を実 行可能 • ローカル環境でのビルド、ビルド環境へログインしての デバッグも可能 • 22種類のユースケースベースのサンプル • https://docs.aws.amazon.com/ja_jp/codebuild/latest/userguide /use-case-based-samples.html
69.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. Q&A お答えできなかったご質問については AWS Japan Blog 「https://aws.amazon.com/jp/blogs/news/」にて 後日掲載します。
70.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. AWS の日本語資料の場所「AWS 資料」で検索 https://amzn.to/JPArchive
71.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved. で[検索]AWS イベント 毎週”W-A個別技術相談会”を実施中 • AWSのソリューションアーキテクト(SA)に 対策などを相談することも可能 • 申込みはイベント告知サイトから (https://aws.amazon.com/jp/about-aws/events/) AWS Well-Architected 個別技術相談会
72.
© 2020, Amazon
Web Services, Inc. or its Affiliates. All rights reserved.© 2020, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS 公式 Webinar https://amzn.to/JPWebinar 過去資料 https://amzn.to/JPArchive ご視聴ありがとうございました