Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

36
~結果発表~ 2013年10月19日(土) @fullvirtue Copyright © @fullvirtue. All rights reserved.

Transcript of Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

Page 1: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

~結果発表~

2013年10月19日(土)

fullvirtue

Copyright copy fullvirtue All rights reserved

chefのおさらい chefの基本について

Copyright copy fullvirtue All rights reserved 2

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの守備範囲

Copyright copy fullvirtue All rights reserved 3 IDCFクラウドでchefを使い始めるまで―第1回 chef Server導入編 httpwwwidcfjpblogcloudchef_01

Puppet chef

歴史 割とある 若い

ユーザー (この分野では) 多い有名企業も使ってる

まだ少ない

開発の活発度 そこそこ 活発 (割と旬な感じ)

ドキュメント 多い まあ十分ぽい

設定ファイル 専用の文法で書く (外部 DSL) Ruby で書く (内部 DSL)

設定の構成 少し分かりにくい 割と分かりやすいネーミングとかしっくりくる

依存関係の処理

実行順は状況に応じてシステム側で決まるMakefile みたい

基本書いた順ぽいPuppet よりはスクリプト風

必要なミドルウェア

特になし サーバ側で CouchDBRabbitMQ が必要

インストール 簡単gem のインストールで済む

サーバ側は軽く死ねるパッケージで入れないとつらいクライアント側は gem だけで済むので簡単

他システムとの連携

あまり売りにはしてない感じ RESTful なサーバ API を使って値が JSON で取得できるのでいろいろやりやすそう

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefが出る前の代替手段との比較

Copyright copy fullvirtue All rights reserved 4 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefのツール群

Copyright copy fullvirtue All rights reserved 5 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

名称 概要

chef-server 情報を集約して管理するサーバプロセス 各 Client とは JSONREST スタイルで通信する

chef-client 設定を適用する各マシンにインストールされるデーモン 定期的に chef-server をポーリングしてその内容に従ってレシピを実行

chef-solo サーバ無しでレシピを実行するツール

knife chef-server に登録されている情報の取得変更を行うツール

webui chef-server の Web インターフェース

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの主な構成要素

Copyright copy fullvirtue All rights reserved 6 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

管理対象マシン

RecipeTemplateAttribute などをひとまと

めにしたディレクトリ

実行内容の定義本体

Recipe 内で行う操作を抽象化して宣言文ぽくしたもの パッケージ管理デーモン管理ファイル管理コマンド実行等

環境依存の処理を吸収するための変数 バイナリファイルなど単にコピーして使うためのファイルを置くところ

Cookbook の説明とかのメタ情報

設定ファイルを生成するためのテンプレート

Node に対して適用する Role や Recipe を指定したリスト

chef-server にアクセスするツール類

複数の Recipe をまとめて「役割」として定義するためのもの

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 2: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chefのおさらい chefの基本について

Copyright copy fullvirtue All rights reserved 2

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの守備範囲

Copyright copy fullvirtue All rights reserved 3 IDCFクラウドでchefを使い始めるまで―第1回 chef Server導入編 httpwwwidcfjpblogcloudchef_01

Puppet chef

歴史 割とある 若い

ユーザー (この分野では) 多い有名企業も使ってる

まだ少ない

開発の活発度 そこそこ 活発 (割と旬な感じ)

ドキュメント 多い まあ十分ぽい

設定ファイル 専用の文法で書く (外部 DSL) Ruby で書く (内部 DSL)

設定の構成 少し分かりにくい 割と分かりやすいネーミングとかしっくりくる

依存関係の処理

実行順は状況に応じてシステム側で決まるMakefile みたい

基本書いた順ぽいPuppet よりはスクリプト風

必要なミドルウェア

特になし サーバ側で CouchDBRabbitMQ が必要

インストール 簡単gem のインストールで済む

サーバ側は軽く死ねるパッケージで入れないとつらいクライアント側は gem だけで済むので簡単

他システムとの連携

あまり売りにはしてない感じ RESTful なサーバ API を使って値が JSON で取得できるのでいろいろやりやすそう

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefが出る前の代替手段との比較

Copyright copy fullvirtue All rights reserved 4 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefのツール群

Copyright copy fullvirtue All rights reserved 5 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

名称 概要

chef-server 情報を集約して管理するサーバプロセス 各 Client とは JSONREST スタイルで通信する

chef-client 設定を適用する各マシンにインストールされるデーモン 定期的に chef-server をポーリングしてその内容に従ってレシピを実行

chef-solo サーバ無しでレシピを実行するツール

knife chef-server に登録されている情報の取得変更を行うツール

webui chef-server の Web インターフェース

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの主な構成要素

Copyright copy fullvirtue All rights reserved 6 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

管理対象マシン

RecipeTemplateAttribute などをひとまと

めにしたディレクトリ

実行内容の定義本体

Recipe 内で行う操作を抽象化して宣言文ぽくしたもの パッケージ管理デーモン管理ファイル管理コマンド実行等

環境依存の処理を吸収するための変数 バイナリファイルなど単にコピーして使うためのファイルを置くところ

Cookbook の説明とかのメタ情報

設定ファイルを生成するためのテンプレート

Node に対して適用する Role や Recipe を指定したリスト

chef-server にアクセスするツール類

複数の Recipe をまとめて「役割」として定義するためのもの

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 3: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの守備範囲

Copyright copy fullvirtue All rights reserved 3 IDCFクラウドでchefを使い始めるまで―第1回 chef Server導入編 httpwwwidcfjpblogcloudchef_01

Puppet chef

歴史 割とある 若い

ユーザー (この分野では) 多い有名企業も使ってる

まだ少ない

開発の活発度 そこそこ 活発 (割と旬な感じ)

ドキュメント 多い まあ十分ぽい

設定ファイル 専用の文法で書く (外部 DSL) Ruby で書く (内部 DSL)

設定の構成 少し分かりにくい 割と分かりやすいネーミングとかしっくりくる

依存関係の処理

実行順は状況に応じてシステム側で決まるMakefile みたい

基本書いた順ぽいPuppet よりはスクリプト風

必要なミドルウェア

特になし サーバ側で CouchDBRabbitMQ が必要

インストール 簡単gem のインストールで済む

サーバ側は軽く死ねるパッケージで入れないとつらいクライアント側は gem だけで済むので簡単

他システムとの連携

あまり売りにはしてない感じ RESTful なサーバ API を使って値が JSON で取得できるのでいろいろやりやすそう

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefが出る前の代替手段との比較

Copyright copy fullvirtue All rights reserved 4 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefのツール群

Copyright copy fullvirtue All rights reserved 5 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

名称 概要

chef-server 情報を集約して管理するサーバプロセス 各 Client とは JSONREST スタイルで通信する

chef-client 設定を適用する各マシンにインストールされるデーモン 定期的に chef-server をポーリングしてその内容に従ってレシピを実行

chef-solo サーバ無しでレシピを実行するツール

knife chef-server に登録されている情報の取得変更を行うツール

webui chef-server の Web インターフェース

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの主な構成要素

Copyright copy fullvirtue All rights reserved 6 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

管理対象マシン

RecipeTemplateAttribute などをひとまと

めにしたディレクトリ

実行内容の定義本体

Recipe 内で行う操作を抽象化して宣言文ぽくしたもの パッケージ管理デーモン管理ファイル管理コマンド実行等

環境依存の処理を吸収するための変数 バイナリファイルなど単にコピーして使うためのファイルを置くところ

Cookbook の説明とかのメタ情報

設定ファイルを生成するためのテンプレート

Node に対して適用する Role や Recipe を指定したリスト

chef-server にアクセスするツール類

複数の Recipe をまとめて「役割」として定義するためのもの

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 4: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

Puppet chef

歴史 割とある 若い

ユーザー (この分野では) 多い有名企業も使ってる

まだ少ない

開発の活発度 そこそこ 活発 (割と旬な感じ)

ドキュメント 多い まあ十分ぽい

設定ファイル 専用の文法で書く (外部 DSL) Ruby で書く (内部 DSL)

設定の構成 少し分かりにくい 割と分かりやすいネーミングとかしっくりくる

依存関係の処理

実行順は状況に応じてシステム側で決まるMakefile みたい

基本書いた順ぽいPuppet よりはスクリプト風

必要なミドルウェア

特になし サーバ側で CouchDBRabbitMQ が必要

インストール 簡単gem のインストールで済む

サーバ側は軽く死ねるパッケージで入れないとつらいクライアント側は gem だけで済むので簡単

他システムとの連携

あまり売りにはしてない感じ RESTful なサーバ API を使って値が JSON で取得できるのでいろいろやりやすそう

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefが出る前の代替手段との比較

Copyright copy fullvirtue All rights reserved 4 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefのツール群

Copyright copy fullvirtue All rights reserved 5 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

名称 概要

chef-server 情報を集約して管理するサーバプロセス 各 Client とは JSONREST スタイルで通信する

chef-client 設定を適用する各マシンにインストールされるデーモン 定期的に chef-server をポーリングしてその内容に従ってレシピを実行

chef-solo サーバ無しでレシピを実行するツール

knife chef-server に登録されている情報の取得変更を行うツール

webui chef-server の Web インターフェース

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの主な構成要素

Copyright copy fullvirtue All rights reserved 6 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

管理対象マシン

RecipeTemplateAttribute などをひとまと

めにしたディレクトリ

実行内容の定義本体

Recipe 内で行う操作を抽象化して宣言文ぽくしたもの パッケージ管理デーモン管理ファイル管理コマンド実行等

環境依存の処理を吸収するための変数 バイナリファイルなど単にコピーして使うためのファイルを置くところ

Cookbook の説明とかのメタ情報

設定ファイルを生成するためのテンプレート

Node に対して適用する Role や Recipe を指定したリスト

chef-server にアクセスするツール類

複数の Recipe をまとめて「役割」として定義するためのもの

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 5: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefのツール群

Copyright copy fullvirtue All rights reserved 5 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

名称 概要

chef-server 情報を集約して管理するサーバプロセス 各 Client とは JSONREST スタイルで通信する

chef-client 設定を適用する各マシンにインストールされるデーモン 定期的に chef-server をポーリングしてその内容に従ってレシピを実行

chef-solo サーバ無しでレシピを実行するツール

knife chef-server に登録されている情報の取得変更を行うツール

webui chef-server の Web インターフェース

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの主な構成要素

Copyright copy fullvirtue All rights reserved 6 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

管理対象マシン

RecipeTemplateAttribute などをひとまと

めにしたディレクトリ

実行内容の定義本体

Recipe 内で行う操作を抽象化して宣言文ぽくしたもの パッケージ管理デーモン管理ファイル管理コマンド実行等

環境依存の処理を吸収するための変数 バイナリファイルなど単にコピーして使うためのファイルを置くところ

Cookbook の説明とかのメタ情報

設定ファイルを生成するためのテンプレート

Node に対して適用する Role や Recipe を指定したリスト

chef-server にアクセスするツール類

複数の Recipe をまとめて「役割」として定義するためのもの

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 6: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

chefのおさらいchefの主な構成要素

Copyright copy fullvirtue All rights reserved 6 chef でサーバ管理を楽チンにしよう (第 1 回) httpmagazinerubyistnet0035-chefInDECOLOGl1

管理対象マシン

RecipeTemplateAttribute などをひとまと

めにしたディレクトリ

実行内容の定義本体

Recipe 内で行う操作を抽象化して宣言文ぽくしたもの パッケージ管理デーモン管理ファイル管理コマンド実行等

環境依存の処理を吸収するための変数 バイナリファイルなど単にコピーして使うためのファイルを置くところ

Cookbook の説明とかのメタ情報

設定ファイルを生成するためのテンプレート

Node に対して適用する Role や Recipe を指定したリスト

chef-server にアクセスするツール類

複数の Recipe をまとめて「役割」として定義するためのもの

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 7: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

今回構築した構成 今回構築した構成について説明します

Copyright copy fullvirtue All rights reserved 7

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 8: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 8

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 9: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

やったこと事前準備 Azureの管理ポータルでやったことについて

Copyright copy fullvirtue All rights reserved 9

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 10: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(15)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Server Workstation)

Copyright copy fullvirtue All rights reserved 10

Windows Azure Chef Server環境用 サブスクリプション

svratithackchef1

アフィニティグループ svratithackchef1affinitygroup

svratithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure Workstation環境用 サブスクリプション

wksatithackchef1

アフィニティグループ wksatithackchef1affinitygroup

wksatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 11: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(25)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成(Chef Client [node]times3環境)

Copyright copy fullvirtue All rights reserved 11

Windows Azure 開発環境用

サブスクリプション

devatithackchef1

アフィニティグループ devatithackchef1affinitygroup

devatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure ステージング環境用 サブスクリプション

stgatithackchef1

アフィニティグループ stgatithackchef1affinitygroup

stgatithackchef

仮想マシン

OpenLogic CentOS 63

Windows Azure 本番環境用

サブスクリプション

relatithackchef1

アフィニティグループ relatithackchef1affinitygroup

relatithackchef

仮想マシン

OpenLogic CentOS 63

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 12: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(35)

Microsoftアカウントを作成中にエラー発生

Copyright copy fullvirtue All rights reserved 13

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 13: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

Workstation用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(45)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 14

Cerf Server用

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 14: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと事前準備(55)

サブスクリプションの調達アフィニティグループ 仮想マシンの作成

Copyright copy fullvirtue All rights reserved 15

本番環境用

ステージング環境用 開発環境用

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 15: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

やったことchef-server chef-serverの構築でやったことについて

Copyright copy fullvirtue All rights reserved 16

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 16: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(17)

1 chef-server のインストール

1 chefのURL取得 httpwwwopscodecomchefinstall

ndash 今回の場合Enterprise Linux rarr 6 rarr x86_64 rarr 1108

raquo httpsopscode-omnibus-packagess3amazonawscomel6x86_64chef-server-1108-1el6x86_64rpm

2 chef server パッケージのインストール

ndash sudo rpm -ivh [1で取得したURL]

Copyright copy fullvirtue All rights reserved 17 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 17: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(27)

2 chef-server のセットアップ

1 前回の処理結果時に表示されていたコマンドを そのまま実行する

ndash sudo chef-server-ctl reconfigure

Copyright copy fullvirtue All rights reserved 18 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 18: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(37)

3 chef-server のセットアップ中にエラー発生

Copyright copy fullvirtue All rights reserved 20 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 19: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(47)

3 chef-server のセットアップ中にエラー発生

ndash ケチって で仮想マシンを作成したら メモリが足りませんでした orz

Copyright copy fullvirtue All rights reserved 21 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 20: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(57)

4 仮想マシンを全部削除後再度作成

1 泣く泣く仮想マシンを削除 times 5環境

2 今度は を選んで仮想マシンを作成 times 5環境

3 chef-server のインストールおよびセットアップ

ndash 同様の手順でダウンロードrarrインストールrarrセットアップを実施

ndash 成功すると以下のようなメッセージが出ます

Copyright copy fullvirtue All rights reserved 22 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 21: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(67)

5 Azureの管理画面からhttps用のエンドポイントを設定

1 エンドポイントの詳細の指定でHTTPSを選択

Copyright copy fullvirtue All rights reserved 23 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 22: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことchef-server(77)

6 ブラウザからchef-serverへアクセス

1 ブラウザから以下のURLへアクセス

ndash https[対象の仮想マシン]cloudappnetuserslogin

2 ログイン後パスワード変更

Copyright copy fullvirtue All rights reserved 24 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

1 ログイン画面に書かれているデフォルトのユーザーパスワードでログイン

2 パスワード変更を求められるので好きなパスワードに変更

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 23: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

やったことworkstation workstationの構築でやったことについて

Copyright copy fullvirtue All rights reserved 25

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 24: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(16)

1 chef-clientのインストール

1 gitパッケージをインストール

ndash sudo yum install git

2 Chef Clientパッケージをインストール

ndash curl -L httpwwwopscodecomchefinstallsh | sudo bash

3 インストールが出来たかどうかをchef-clientコマンドで確認

ndash chef-client -v

Copyright copy fullvirtue All rights reserved 26 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 25: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(26)

2 Cookbook開発環境の構築

1 WorkstationでCookbook開発などに利用するユーザー(一般 ユーザー)のホームディレクトリ以下にchefディレクトリを作成

ndash mkdir ~chef

2 Chef Serverのetcchef-serverディレクトリにある秘密鍵 adminpemとchef-validatorpemの二つをWorkStationにコピー

Copyright copy fullvirtue All rights reserved 27 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 26: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったことworkstation(36)

3 Cookbook開発に必要なディレクトリファイルを作成

1 gitより取得

ndash cd

ndash git clone gitgithubcomopscodechef-repogit

2 初期設定を実施

ndash cd chef-repo

ndash sudo knife configure --initial

Copyright copy fullvirtue All rights reserved 28 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 27: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (46)

4 初期設定を実施中にエラー発生

Copyright copy fullvirtue All rights reserved 30 【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 28: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (56)

5 初期設定をやりなおすもエラー再発

Copyright copy fullvirtue All rights reserved 31

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 29: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

やったこと workstation (66)

6 サーバー名を変更するもタイムアウトでエラー

Copyright copy fullvirtue All rights reserved 32

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 30: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

最終結果 今回のハッカソンの進捗結果

Copyright copy fullvirtue All rights reserved 33

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 31: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回構築した構成

Copyright copy fullvirtue All rights reserved 34

Cerf Server用

Workstation用

開発環境用

ステージング環境用

本番環境用

【chef 11版】chef Server環境セットアップ手順の紹介 httpwwwidcfjpblogcloudchef-11

初期設定中に Serverに繋がらず

仮想マシンを用意しただけで終わった

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 32: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

chef+Vagrantでクラウド環境構築自動化ハッカソン atithack

今回作成したAzureのアイテム達

Copyright copy fullvirtue All rights reserved 35

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました

Page 33: Chef+Vagrantでクラウド環境構築自動化ハッカソン 結果発表 #atithack

Copyright copy fullvirtue All rights reserved 36

ご静聴ありがとうございました