powershell desired state configuration for linux
play

PowerShell Desired State Configuration for Linux By: Kolby - PowerPoint PPT Presentation

PowerShell Desired State Configuration for Linux By: Kolby Allen August 19, 2015 LINUXCON North America Outline - What is PowerShell and Desired State Configuration?


  1. PowerShell ¡Desired ¡State ¡ Configuration ¡for ¡Linux By: ¡Kolby ¡Allen August ¡19, ¡2015 LINUXCON ¡North ¡America

  2. Outline -­‑ What ¡is ¡PowerShell ¡and ¡Desired ¡State ¡Configuration? -­‑ Why ¡would ¡I ¡use ¡PowerShell ¡for ¡Linux? -­‑ Review ¡of ¡Desired ¡State ¡Configuration -­‑ Server ¡Setup -­‑ Client ¡Setup -­‑ Examples -­‑ Webserver ¡Configuration -­‑ End ¡to ¡End ¡Provisioning ¡(Hyper-­‑V ¡to ¡Webserver) -­‑ Q/A 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 2

  3. What ¡is ¡PowerShell? -­‑ PowerShell ¡– task ¡automation ¡and ¡management ¡tool -­‑ Allow ¡for ¡both ¡local ¡and ¡remote ¡management -­‑ Scripting ¡language -­‑ V1 ¡shipped ¡in ¡2006 ¡as ¡optional -­‑ V2 ¡shipped ¡with ¡Win7 ¡and ¡Server ¡2008 -­‑ V5 ¡currently ¡in ¡preview ¡(unless ¡your ¡on ¡Win10?) Reboot ¡Local ¡Machine: Restart-Computer Reboot ¡Remote ¡Machine: Restart-Computer -ComputerName Server01 Reboot ¡Remote ¡Machines ¡(multiple): Restart-Computer -ComputerName Server01, Server02, localhost 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 3

  4. What ¡is ¡Desired ¡State ¡Configuration? -­‑ PowerShell ¡Desired ¡State ¡Configuration ¡was ¡released ¡to ¡allow ¡for ¡ deployment ¡and ¡management ¡of ¡configuration ¡data -­‑ Follows ¡DMTF ¡management ¡standards ¡and ¡WS-­‑Management ¡Protocol -­‑ Applications: -­‑ Server ¡role/feature ¡management -­‑ Setting/Changing ¡registry ¡items -­‑ Process/service ¡management -­‑ User/Group ¡Management -­‑ Software ¡Deployment ¡and ¡setup -­‑ Remote ¡script ¡execution -­‑ Managing ¡configuration ¡drift -­‑ Actual ¡configuration ¡reporting 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 4

  5. Why ¡use ¡DSC? WHY ¡NOT ¡ONE ¡OF ¡THESE? 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 5

  6. Why ¡use ¡DSC? Because ¡of ¡this… 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 6

  7. Review ¡of ¡DSC ¡– Server ¡Setup ¡-­‑ PUSH Start-DscConfiguration Remote Machine Local Target configuration LCM Configurations Remote Machine configuration Local Configuration Manager (LCM) LCM Push ¡Server http://blogs.msdn.com/b/powershell/archive/2013/11/26/push-­‑and-­‑pull-­‑configuration-­‑modes.aspx 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 7

  8. Review ¡of ¡DSC ¡– Server ¡Setup ¡-­‑ PUSH Author Generate Push Configuration MOF Configuration http://blogs.msdn.com/b/powershell/archive/2013/11/26/push-­‑and-­‑pull-­‑configuration-­‑modes.aspx 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 8

  9. Review ¡of ¡DSC ¡– Server ¡Setup ¡-­‑ PULL Pull ¡Server get DSC OData Endpoint Remote Machine LCM send IIS Service get Configurations Remote Machine LCM send Resources http://blogs.msdn.com/b/powershell/archive/2013/11/26/push-­‑and-­‑pull-­‑configuration-­‑modes.aspx 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 9

  10. Review ¡of ¡DSC ¡– Server ¡Setup ¡-­‑ PULL Author Setup Pull Setup DSC Configuration Server on target for Target http://blogs.msdn.com/b/powershell/archive/2013/11/26/push-­‑and-­‑pull-­‑configuration-­‑modes.aspx 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 10

  11. Review ¡of ¡DSC ¡– Client ¡Setup Support ¡Operating ¡Systems Required ¡Packages: CentOS5, ¡6, ¡& ¡7 • -­‑ glibc -­‑ python Debian GNU/Linux ¡6 ¡& ¡7 • -­‑ omniserver -­‑ Open ¡Management ¡ Oracle ¡Linux ¡5, ¡6, ¡& ¡7 • Infrastructure RHEL ¡5, ¡6, ¡& ¡7 • -­‑ openssl SUSE ¡10, ¡11, ¡& ¡12 • -­‑ ctypes Ubuntu ¡12.04 ¡LTS ¡& ¡14.04 ¡LTS • -­‑ libcurl DSC ¡for ¡Linux ¡Binaries https://github.com/MSFTOSSMgmt/WPSDSCLinux 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 11

  12. Review ¡of ¡DSC ¡– Client ¡Setup ¡– LINUX ¡Resources DSC ¡Resources ¡– building ¡blocks ¡to ¡DSC ¡Configurations Linux ¡Resources nxFile – manages ¡files ¡and ¡directory ¡state • nxScript – run ¡script ¡blocks ¡on ¡target ¡nodes • nxUser – manages ¡linuxusers • nxGroup – manages ¡linuxgroups • nxService – manages ¡linux services ¡(System-­‑V, ¡upstart, ¡systemd) • Currently ¡in ¡beta ¡but ¡growing. 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 12

  13. DSC ¡Examples ¡– DSC ¡Configuration Servers ¡installed ¡on Force ¡feature ¡to ¡be ¡installed Adds ¡file ¡to ¡OS 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 13

  14. DSC ¡Examples ¡– DSC ¡Configuration ¡– Windows ¡WebServer 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 14

  15. DSC ¡Examples ¡– Demo DEMO 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 15

  16. DSC ¡Examples ¡– End ¡to ¡End ¡Provisioning Most ¡corporate ¡environments ¡use ¡Hyper-­‑V ¡or ¡VMWare • Hyper-­‑V ¡has ¡DSC ¡Resources ¡(form ¡MS) • VMWare ¡Powershell tools ¡(requires ¡custom ¡DSC ¡Resource) • Just ¡requires ¡that ¡you ¡have ¡built ¡a ¡VM ¡with ¡all ¡pre-­‑reqs • Hyper-­‑V ¡and ¡PS ¡DSC ¡for ¡Linux ¡support ¡the ¡same ¡operating ¡services • Once ¡VM ¡is ¡deployed ¡you ¡can ¡use ¡DSC ¡push ¡server ¡to ¡do ¡initial ¡setup • 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 16

  17. DSC ¡Examples ¡– End ¡to ¡End ¡Provisioning ¡– Hyper-­‑V http://mikefrobbins.com/2015/01/22/creating-­‑hyper-­‑v-­‑vms-­‑with-­‑desired-­‑state-­‑configuration/ 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 17

  18. Review ¡of ¡DSC ¡– Conclusion DSC ¡Provides ¡a ¡new ¡set ¡of ¡tools ¡for ¡machine ¡configuration • Allows ¡integration ¡with ¡current ¡Windows ¡SysAdmintoolset • Hyper-­‑V ¡and ¡VMWare ¡end ¡to ¡end ¡provision ¡capabilities • A ¡new ¡tool ¡to ¡manage ¡servers • 8/19/2015 PowerShell ¡DSC ¡for ¡Linux 18

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend