ç§ã PowerShell ãããçç±ã好ããªçç±ãä»èªåã æããå¿ è¦ããããã¨ããã㯠Windows ã«ããããããã¤ã§ãããç§ã PowerShell ã«èå³ãæã£ã¦ãããã¹ã¦ã§ãã
Linux 大好ãã§ããDeploy ã Automation ã®ãã¬ã³ã㯠Linux çéãè¦ãã¨æ¥½ããã§ãã
Windows è¶ å¥½ãã§ããC# 大好ãã§ããã¯ã©ã¦ãæé«ã§ãããªã®ã§ è¬ç¤¾ ã® ãµã¼ãã¼ã¯ Amazon Web Service ä¸ã® Windows Server 2012 ã§ãã*1 ãããªWindows ã«ããããããã¤ã« PowerShell ãã©ã使ã£ã¦æ¥½ã«ããã®ããæ¯æ¥èãã¦ãã¾ãã
ã§ããWindows 㧠ãããã¤ï¼ ã©ãããã®ï¼ ã¨ããããã¨å®ä¾ãä¹ããææ³ãæ®åãã¦ããªãæ®å¿µãªç¾å®ããªã®ã§ãä»åã¯ãããèãã¦è¦ã¾ãã
- Windows ã§ã® Deploy ã« PowerShellãæããå½¹å²
- ãããã¤ã£ã¦ãªã«
- ããããã® PowerShell
- 2014å¹´ã®ãããã¤
- ä»å¾
Windows ã§ã® Deploy ã« PowerShellãæããå½¹å²
JPPOSH - 第äºåPowerShellåå¼·ä¼ ã¨ãããã¨ã§ã 2014å¹´4æ12æ¥ã«è¡ããã PowerShellåå¼·ä¼@å¤§éª ã§ãWindowsã«ããããããã¤ã«ã¤ãã¦ã話ãã¦ãã¾ããã
ååã®åå¼·ä¼ã§ãããã§ããããã©ããå 容ãè¨ãã㧠æéå ã«è©±ãã£ã¦ãã¾ãããããããªããã
ãè©«ã³ã¨ãã£ã¦ã¯ãªãã§ãããè£è¶³èª¬æã¨ãå¢éãã¦ããã¾ããã*2 åå ãããæ¹ãåå ããã¦ããªãæ¹ãããã²èªãã§ããã ããã¨å¹¸ãã§ãã
èãä¸è¶³ãªé¨åããããã¨æãã®ã§ãçªã£è¾¼ã¿ããå¾ ã¡ãã¦ããã¾ãã
ä»ã®ç»å£è ã®è³æ
ãªã³ã¯ãç½®ãã¦ããã¾ãã
ç»å£è | æ¦è¦ | ãªã³ã¯ |
---|---|---|
çç°å£å¤§ä» | PowerShellãåãå ¥é 2014 | winscript |
waka | PowerShellãã¯ã©ã¤ã¢ã³ãã§æ´»ç¨ | PowerPoint Web App |
Chuki | PowerShell 㨠Active Directory | SlideShare |
ä»ã®æ¹ã¨å 容ãéãããã¦ä¼å ´ãç½®ãã¦ãã¼ãã«ããæãã³ããã¤ã§ããåçãã¦ãã¾ããå¾æã¯ãã¦ãã¾ããã
ä¼ããããã¨
ä»åãDSC ã¨ãããããºã¯ã¼ãã使ã£ã¦ã»ãã·ã§ã³ãã¦ãã¾ãããä¼ãããã®ã¯ Windows 㯠PowerShellã使ãã°æ¥½ã«ãªããã楽ãããã ã§ãã DSCãä½ã¨ããDSC ã使ã£ã¦ããã§ã¯ããã¾ããã
- å®éã«ã¯ã©ã¦ãä¸ã«å±éãã100å°ãè¶ ãããµã¼ãã¼ã«å¯¾ãã¦ãã©ããããã¤ãèªååããã®ããDSC ãããã«æããå½¹å²ã¨ã¯
- DSCãåºããã©ãä»å¾ã®ãããã¤ã£ã¦ã©ããªãã®ãDSCã§æºè¶³ã§ããã®ï¼
- DSC ã§æ³¨æãããã¨ã¨ãããï¼
Windowsã§ã®ããã㤠㧠PowerShell ã使ããã®ãããããã¤ãã·ã¼ã³ã«æãã¦ãã¾ãããã·ã¹ãã 管çè ã§ãå¿ç¨ã§ããé¨åã¯ããããããã¾ãã
大äºãªã®ã¯ãã©ã PowerShell ã使ã£ã¦æ¥½ãããããã§ãPowerShell ã使ããã¨ã§ã¯ããã¾ããã
ãããã¤ã£ã¦ãªã«
ä¸è¨ã§ ãããã¤ã£ã¦ãã£ã¦ããã¬ã¤ã¤ã¼ãåãããã¨ãã§ãã¾ããã¨ãããããã¬ã¤ã¤ã¼ãåããã«èããã®ã¯ARIENAIã
ã¾ãã¯ãèããä¸ã§åèã«ãªãããããã
ç§ã¯ Linux ã«éãã Windows ã§ãåæ§ã«ã¬ã¤ã¤ã¼ãåãã¦èããã¹ãã ã¨æã£ã¦ãã¾ãããã®èãã«OSã®éãã¨ããªãã§ããã
ãã ãããããã®ã¬ã¤ã¤ã¼ã®æ確ãªå®ç¾©ã£ã¦çµæ§ããã¾ã..... ãªã¤ã¡ã¼ã¸... (åå¼·ä¸è¶³)
ãªã®ã§ããã£ãã 4層ã§èãã¦ãã¾ãã*3
Configuration
OS ã ããã«ã¦ã§ã¢ã¬ãã«ã®ãããã¸ã§ãã³ã°ãéçãªè¨å®ã®èªååãè¡ã層ã
- å ¨ãµã¼ãã¼ã§è¨å®ãç¶æ (Configuartion) ãåããã
- ç¶æ ãã³ã¼ãã«è½ã¨ããã¿ãããã¹ãç¶æ ãããã°ã©ããã«ã«ç®¡çãã
- ä½åº¦å®è¡ãã¦ããããã¹ãç¶æ ã«åæãã
Orchestration
1ã¤ä¸ã¤ã®ã·ã¹ãã (ãµã¼ãã¼ã¨ããã¼ããã©ã³ãµã¼ã¨ãè²ã ) ã å ¨ä½ã®ãµã¼ãã¹ (ã²ã¼ã ) ã¨ãã¦å調åä½ããã層ã
- Capistrano ã¨ã fabric ã«ãã ã¢ããªã®ãããã¤
- ãµã¼ãã¼ã®åçãªè¨å®ã¨ãã®èªåå
Cluster Management
ä»ãµã¼ãã¹ããã¼ãã¨ã®å調çãªåä½ãèªå¾çã«è¡ã層ã*4
åãå½¹å²ã®åãã¼ãã¨ä»ãã¼ãã®å調çãªåä½
- ãµã¼ãã¼Aãç¶æ å¤åããã¨ãã«ãä»ã®ãµã¼ãã¼B,Cã«éå²
- ãµã¼ãã¼B,C ã¯èªèº«ã®è¨å®ãããµã¼ãã¼Aã®éç¥ãåããå 容ãé©ç¨
ãã¼ãã¨ä»ãµã¼ãã¹ãå調çã«åä½
- ãã¼ãD ãåæ¢ããã¨ãã«ããã¼ããã©ã³ãµã«éç¥ãã¦ããã¼ãDã«åç §ãå²ãæ¯ããªãããã«è¨å®ãé©ç¨ãããªã©
Bootstrapping
ä»åã¯è§¦ãã¦ãã¾ãããããOSã®èªåã¤ã³ã¹ãã¼ã«ããã·ã³ã®èªåéå§ãªã©ã®ä½ã¬ã¤ã¤ã¼ãªèªååã®å±¤ã
- AWS ã§ã®ã¤ã³ã¹ã¿ã³ã¹ã®éå§ãªã©
- Azure ã§ãåæ§ã«VMã®éå§ãªã©
ããããã® PowerShell
PowerShell ã¯ã¯ã©ã¦ãã§ã®ãããã¤ã«ã·ãã
Microsoft ã Rapidãªãªã¼ã¹ã«Azureãä¸å¿ã¨ããã¯ã©ã¦ãå±éã«èµããã£ãããã«ãPowerShell ãã¼ã ã Agileã«ãRapidãªãªã¼ã¹ã«èµããã£ã¦ãã¾ãã
PowerShell Remoting (v2) â WorkFlow ã«ãã Orchestration (v3) â DSC ã«ãã Configuration (v4) â OneGet ã«ãã ap-get ã©ã¤ã¯ãªããã±ã¼ã¸ç®¡ç (v5)
PowerShell ã®æ°æ©è½ã Automation ã¨ããæ¬è³ªã¯ãã®ã¾ã¾ã«ã Cloud ã§ã®å±éã«ã·ãããã¦ãã¾ãã
ãããã Windows 㧠Cloud å±éãããæã«ãPowerShell ãæåãªæ段ã¨ãªãããã®å®ä¾ã¨ææãã ãã¦ããããã¨æãã¾ãã
ã³ãã¥ãã£ã®æ´»åã¯å¤§äº
DSC ã¯ãã ã®ãã¼ã«ã§ãDSCãåºãããã¨ãã£ã¦ ãããã¤ã楽ã«ãªããã¨ããã¨ããã£ã±ãã¾ã ã¾ã ã§ããLinux çéã§ã® ãããã¤ææ³ãWindowsã§ãããããã§ãããã ã£ã¦å¿ è¦ã§ãããç¹ã«ã³ã³ãããã¼ã¹ã®å±éããã¼ãã®èªå¾çãªåä½ãã
Linux ã Windows ã«æ¯ã¹ã¦è¶ ç´ æµãªã®ã¯ãªã¼ãã³ã½ã¼ã¹ãªã³ãã¥ããã£ãè±å¯ã§æ´»çºã ããã§ããMicrosoft ããããé å¼µã£ã¦ããæ´»çºãªã³ãã¥ããã£ããçã¿åºãããç´ æµãªèãããããã¯ãã«ã¯åã³ã¾ããããªã¼ãã³ã½ã¼ã¹ã³ãã¥ããã£ããã£ã¨æ´»çºã«ã大äºã«ã
DSC ã«ãªã½ã¼ã¹ããªãï¼ãªãä½ãã°ããã®ã§ãããªã½ã¼ã¹è¿½å ãé¢åï¼ãªã楽ã«ãªãããã«ããã°ããã®ã§ããã³ãã¥ããã£ã主å°ãã¦ããªã½ã¼ã¹ãå±éããæ´»çºãªããåãã PowerShell ãã¼ã ãæå¾ ãã¦ããããã§ãã
2014å¹´ã®ãããã¤
Immutable Infrastructure
2013å¹´ã® Docker ã StatelessãSerf ã¨ããææããã2014å¹´ãã¬ã³ãã¨å®çªã¸ã®çºå±ã¨ãªãã¤ã¡ã¼ã¸ã§ãã
ãã Immutableã«ããã°ããã£ã¦ãããã®ã§ã¯ãªãã®ã§ãããã¯æ³¨æã§ãã
ã¤ã³ãã©çã«ãã¤ã³ãã¨ãªãã®ããbox (ã³ã³ãã) ã®é«éå±éã§ãã ãã㧠Docker ãåºã¦ãã¾ãã
Microsoft 㯠vagrant ã¸ã® Windows Server 2012 R2 ã®ã¤ã¡ã¼ã¸ãæä¾ãããªã©ãç©æ¥µçã§ãã2014/6/28 ã¾ã§è©¦ç¨å¯è½ãª vagrant box ãå ¬éããã¦ããã®ã§ãã©ããã
ä»ã«ãããã¼ãã®å¤åãä»ãµã¼ãã¹ã¨é£æºããããã®Serfãã¢ããªã Immutable ãåæã«ãããªã©ã®é£æºãå¿ è¦ã§ãããããã¯ã¾ãã®æ©ä¼ã«ã
Windows ã§ã¯ã©ããªã®
åç´ã« Immetable ã«ããã«ã¯ãã¾ã ç¾ç¶é£ããã¨èãã¦ãã¾ããã§ããããã®è¾ºã¯ãããããèãã¦ããããã§ãã
ä»å¾
次åã® PowerShell åå¼·ä¼ ãæ±äº¬ã§ 6æã7æã«è¡ããã°ã¨èãã¦ãã¾ããåç¥ã¯ãJPPOSH ã§è¡ã£ã¦ããã¾ãã®ã§ãä»åº¦ã¨ããããããé¡ããããã¾ãã*5
*1:Windows Server 2012 R2 ã¾ã ã¼ï¼
*2:ã©ããå ¨ã¦åã£ã¦ãªããã¤ã±ãã¤ã±ãï¼
*3:ã»ãã·ã§ã³è³æã§ã¯ Bootstraping ãã¯ããã¦3層ã¨ãã¦ãã¾ã
*4:æ£ç´ Orchestration ã¨è¢«ã£ã¦ããã®ã§ãåãããæ©ããåããªãã¦ãã¨ããæ°ããã¾ãããããã£ããåãã¾ããã
*5:PULLã¢ã¼ãã§ã® DSC ã«ãã Configurationãé¡æã«æããã°ã¨æãã¾ãã