SlideShare une entreprise Scribd logo
1  sur  30
Windows Nano Server & Puppet
Alessandro Pilotti
Cloudbase Solutions
http://cloudbase.it
@cloudbaseit
Agenda
Nano Server
Puppet on Nano Server
Managing resources
DSC + Puppet
Demos
What is Nano Server?
A lightweight installation option for Windows Server
Optimized for cloud deployments
Optimized footprint, a few hundred megabytes!
Fast boot times
Windows without Windows
What can I do with Nano Server?
Included Packages
Hyper-V
Shielded VM
Windows Containers (including Docker)
File Server (including SoFS / S2D)
IIS / ASP.Net 5
Windows Failover Clustering
DNS
SCVMM
DSC
Additional Packages
OpenStack
Availability?
Released with Windows Server 2016
Currently available in Technical Preview (TP5)
Get a Windows Server 2016 TP5 ISO from:
https://microsoft.com/en-us/evalcenter/evaluate-windows-server-technical-
preview
Limitations
Nano Server’s API surface is limited!
Includes “reverse forwarders” for compatibility with existing binaries
Any API that requires Windows GUI / shell interaction is missing or not
implemented
Win64
.Net CoreCLR is portable (Windows, Linux, OS X) but more limited
compared to the Full CLR
Limitations
Some CLI differences
PowerShell differences
No MSI
No ADSI (used by puppet for managing users and groups)
COM STA mode not available (only MTA)
No COM monikers
In general porting applications to run on Nano requires some effort
How to check application compatibility?
Windows API (Native apps, C/C++, etc):
NanoServerApiScan.exe
.Net Core
https://github.com/Microsoft/dotnet-apiport
Build a Nano Server image for bare metal
or Hyper-V
Get a Windows Server 2016 TP5 ISO from https://www.microsoft.com/en-us/evalcenter/evaluate-
windows-server-technical-preview
Example:
Packages can be added (Hyper-V, IIS, etc)
Select –DeploymentType Host for physical servers
A custom unattend.xml can be provided for apps deployment / configuration
No need for activation!
New-NanoServerImage -Edition Standard -DeploymentType Guest -MediaPath f:
-BasePath .Base -TargetPath .Nano1Nano.vhd -ComputerName Nano1
What about OpenStack, KVM, ESXi, MAAS,
etc?
PowerShell script to add additional features and target formats:
https://github.com/cloudbase/cloudbase-init-offline-install
..NewNanoServerImage.ps1 -IsoPath C:WindowsServerTP5.iso `
-TargetPath C:Nano.qcow2 -Platform KVM `
-AdministratorPassword $password `
-Compute -Storage -Clustering `
-ExtraDriversPaths C:DevDriversNUC_2015_Intel_ndis64
` -AddCloudbaseInit
` -AddMaaSHooks
` -MaxSize 1500MB
` -DiskLayout "BIOS"
Managing Nano Server
On a Hyper-V host:
PowerShell remoting is available also on regular Windows! This is the native equivalent of SSH on
Windows
How to copy files remotely:
$c = Get-Credential
Enter-PSSession <NanoServer> -Credential $c
Enter-PSSession –VMName <NanoServerVMName> -Credential $c
$s = New-PSSession <NanoServer> -Credential $c
Copy –ToSession $s –Path c:SomeFiles –Destination c:SomeRemoteDir
Install packages
Windows equivalent of apt-get
find-packageprovider
find-package -provider nuget -source http://www.nuget.org/api/v2
install-package node.js -destination c:node -provider nuget -source http://www.nuget.org/api/v2
OpenStack + Nano Server
https://cloudbase.it/openstack-windows-nano-server/
Cloudbase-Init support
→ Including Heat templates support
Works on OpenStack supported hypervisors:
→ Hyper-V
→ KVM
→ ESXi
Add packages at runtime
Install-PackageProvider NanoServerPackage
Find-NanoServerPackage -name *
Find-NanoServerPackage Microsoft-NanoServer-IIS-Package | `
Install-NanoServerPackage -culture en-us
Create a Nano Server instance
Offline domain join
No need to share sensitive domain credentials!
On a domain joined host:
Copy blob.txt to the host that needs to join the domain and run:
Works on Windows Server 2008 R2 and above as well!
djoin /provision /domain cloudbase.demo /machine nanotp5 /savefile blob.txt
djoin /requestODJ /loadfile blob.txt /windowspath %SystemRoot% /localos
Puppet on Nano Server
Puppet is based on Ruby 2.x and C++
Ruby works on Nano Server with
some minor changes:
Win32ole
win32-dir
Facter needs also minor changes
(both Ruby and native ones)
Some resource types do not work
ATM, e.g. users and groups
Other providers require minor
changes, e.g.:
Puppetlabs-dsc
Puppetlabs-reboot
How to create packages on Nano Server
MSI are not supported on Nano Server
Nano Server has a new packaging model called Windows Server Apps (WSA) based on
APPX
Packages include a directory tree and some extensions: NT services, WMI providers,
COM servers
An XML manifest file is needed
Appx packages need to be signed
Deployment:Add-AppxPackage puppet.appx
Get-AppxPackage puppet
Remove-AppxPackage puppet
A Puppet APPX package
Here’s a Puppet for Nano Server package: https://github.com/cloudbase/puppet-nano-server
For creating the package, you need the latest Windows 10 SDK (10.0.14332.1000 or
above)
The certificate CN must match the publisher’s identity in the certificate
makeappx pack /d puppet-nano-server /p puppet.appx
signtool.exe sign /fd sha256 /sha1 xxxxxxxxxxxxxxxxxxxxx /t http://timestamp.verisign.com/scripts/timstamp.dll /v
puppet.appx
Puppet and Nano Server
Some notable modules:
puppetlabs-powershell
puppetlabs-acl
puppetlabs-reboot
puppetlabs-dsc
Some widely used Windows modules and resource types don’t work, e.g.:
puppet-iis is based on the PowerShell WebAdministration module (Not available on Nano)
scheduled_task requires mstask.dll, not available on Nano Server
How to manage local users and groups
ADSI is not supported on Nano, so until Puppet will add an alternative (e.g.
Win32):
$username = 'nano'
$password = 'P@ssw0rd'
$groupname = 'puppet'
exec { 'new-local-group':
command => "New-LocalGroup -Name ${groupname}",
unless => "Get-LocalGroup -Name ${groupname}",
provider => powershell,
}
How to manage local users and groups
exec { 'new-local-user':
command => "New-LocalUser -Name ${username} –Password 
(ConvertTo-SecureString -AsPlainText "${password}" -Force) 
-PasswordNeverExpires",
unless => "Get-LocalUser -Name ${username}",
provider => powershell,
}
exec { 'add-local-group-member':
command => "Add-LocalGroupMember -Group ${groupname} -Member ${username}",
unless => "Get-LocalGroupMember -Group ${groupname} -Member ${username}",
provider => powershell,
require => [Exec['new-local-group'], Exec['new-local-user']],
}
DSC and Puppet
PowerShell Distributed State Configuration
(DSC)
DSC is a declarative platform used for
configuration, deployment, and
management of systems
Similar in scope to Puppet
The puppetlabs-dsc module offers a bridge
between puppet and DSC
Allows to use DSC resources, no need to
rewrite them for Puppet
Only a few resources work on Nano for the
time being (technical preview)
Notice the dsc_ prefix
dsc_registry {'registry_test':
dsc_ensure => 'Present',
dsc_key => 'HKEY_LOCAL_MACHINESOFTWAREExampleKey',
dsc_valuename => 'TestValue',
dsc_valuedata => 'TestData',
Demo
Licensing
Windows licensing is surprisingly easy in OpenStack
→ Datacenter license => unlimited instances
→ 1 license per socket => per core in 2016
→ Works with Hyper-V, VMWare, KVM, etc
→ Very cost effective (a few USD / month per VM)
Volume licensing
Multitenant? SPLA
Q&A
cloudbase.it | @cloudbaseit

Contenu connexe

Tendances

Openstack devops challenges
Openstack devops challenges Openstack devops challenges
Openstack devops challenges
openstackindia
 

Tendances (20)

OpenStack Cinder
OpenStack CinderOpenStack Cinder
OpenStack Cinder
 
[OpenStack Days Korea 2016] Track4 - OpenStack with Kubernetes
[OpenStack Days Korea 2016] Track4 - OpenStack with Kubernetes[OpenStack Days Korea 2016] Track4 - OpenStack with Kubernetes
[OpenStack Days Korea 2016] Track4 - OpenStack with Kubernetes
 
Introduction to OpenStack Cinder
Introduction to OpenStack CinderIntroduction to OpenStack Cinder
Introduction to OpenStack Cinder
 
OpenStack and Windows - What's new in Ocata
OpenStack and Windows - What's new in OcataOpenStack and Windows - What's new in Ocata
OpenStack and Windows - What's new in Ocata
 
CloudStack Conference Public Clouds Use Cases
CloudStack Conference Public Clouds Use CasesCloudStack Conference Public Clouds Use Cases
CloudStack Conference Public Clouds Use Cases
 
Tối ưu hiệu năng đáp ứng các yêu cầu của hệ thống 4G core
Tối ưu hiệu năng đáp ứng các yêu cầu của hệ thống 4G coreTối ưu hiệu năng đáp ứng các yêu cầu của hệ thống 4G core
Tối ưu hiệu năng đáp ứng các yêu cầu của hệ thống 4G core
 
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
Deploying containers and managing them on multiple Docker hosts, Docker Meetu...
 
Wido den hollander cloud stack and ceph
Wido den hollander   cloud stack and cephWido den hollander   cloud stack and ceph
Wido den hollander cloud stack and ceph
 
Integrating CloudStack & Ceph
Integrating CloudStack & CephIntegrating CloudStack & Ceph
Integrating CloudStack & Ceph
 
HP Advanced Technology Group: Docker and Ansible
HP Advanced Technology Group: Docker and AnsibleHP Advanced Technology Group: Docker and Ansible
HP Advanced Technology Group: Docker and Ansible
 
Ceph and OpenStack - Feb 2014
Ceph and OpenStack - Feb 2014Ceph and OpenStack - Feb 2014
Ceph and OpenStack - Feb 2014
 
머신 중심에서 애플리케이션 중심으로 불변의 인프라스트럭처 개념 이해
머신 중심에서 애플리케이션 중심으로 불변의 인프라스트럭처 개념 이해머신 중심에서 애플리케이션 중심으로 불변의 인프라스트럭처 개념 이해
머신 중심에서 애플리케이션 중심으로 불변의 인프라스트럭처 개념 이해
 
OpenStack Neutron behind the Scenes
OpenStack Neutron behind the ScenesOpenStack Neutron behind the Scenes
OpenStack Neutron behind the Scenes
 
Openstack devops challenges
Openstack devops challenges Openstack devops challenges
Openstack devops challenges
 
Deep Dive into Openstack Storage, Sean Cohen, Red Hat
Deep Dive into Openstack Storage, Sean Cohen, Red HatDeep Dive into Openstack Storage, Sean Cohen, Red Hat
Deep Dive into Openstack Storage, Sean Cohen, Red Hat
 
Openstack Study Nova 1
Openstack Study Nova 1Openstack Study Nova 1
Openstack Study Nova 1
 
State of Containers in OpenStack
State of Containers in OpenStackState of Containers in OpenStack
State of Containers in OpenStack
 
OpenStack Summit Vancouver: Lessons learned on upgrades
OpenStack Summit Vancouver:  Lessons learned on upgradesOpenStack Summit Vancouver:  Lessons learned on upgrades
OpenStack Summit Vancouver: Lessons learned on upgrades
 
Unikernels: Rise of the Library Hypervisor
Unikernels: Rise of the Library HypervisorUnikernels: Rise of the Library Hypervisor
Unikernels: Rise of the Library Hypervisor
 
Docker for Java Developers
Docker for Java DevelopersDocker for Java Developers
Docker for Java Developers
 

En vedette

Red hat ceph storage customer presentation
Red hat ceph storage customer presentationRed hat ceph storage customer presentation
Red hat ceph storage customer presentation
Rodrigo Missiaggia
 

En vedette (20)

OpenStack + Nano Server + Hyper-V + S2D
OpenStack + Nano Server + Hyper-V + S2DOpenStack + Nano Server + Hyper-V + S2D
OpenStack + Nano Server + Hyper-V + S2D
 
Building a Microsoft cloud with open technologies
Building a Microsoft cloud with open technologiesBuilding a Microsoft cloud with open technologies
Building a Microsoft cloud with open technologies
 
Red Hat Storage Day New York - What's New in Red Hat Ceph Storage
Red Hat Storage Day New York - What's New in Red Hat Ceph StorageRed Hat Storage Day New York - What's New in Red Hat Ceph Storage
Red Hat Storage Day New York - What's New in Red Hat Ceph Storage
 
The Future of Cloud Software Defined Storage with Ceph: Andrew Hatfield, Red Hat
The Future of Cloud Software Defined Storage with Ceph: Andrew Hatfield, Red HatThe Future of Cloud Software Defined Storage with Ceph: Andrew Hatfield, Red Hat
The Future of Cloud Software Defined Storage with Ceph: Andrew Hatfield, Red Hat
 
Red Hat Ceph Storage: Past, Present and Future
Red Hat Ceph Storage: Past, Present and FutureRed Hat Ceph Storage: Past, Present and Future
Red Hat Ceph Storage: Past, Present and Future
 
Red hat ceph storage customer presentation
Red hat ceph storage customer presentationRed hat ceph storage customer presentation
Red hat ceph storage customer presentation
 
Red Hat Storage Day Boston - Why Software-defined Storage Matters
Red Hat Storage Day Boston - Why Software-defined Storage MattersRed Hat Storage Day Boston - Why Software-defined Storage Matters
Red Hat Storage Day Boston - Why Software-defined Storage Matters
 
PuppetConf 2016: Building Nano Server Images with Puppet and DSC – Michael Sm...
PuppetConf 2016: Building Nano Server Images with Puppet and DSC – Michael Sm...PuppetConf 2016: Building Nano Server Images with Puppet and DSC – Michael Sm...
PuppetConf 2016: Building Nano Server Images with Puppet and DSC – Michael Sm...
 
Accelerating Business Intelligence Solutions with Microsoft Azure pass
Accelerating Business Intelligence Solutions with Microsoft Azure   passAccelerating Business Intelligence Solutions with Microsoft Azure   pass
Accelerating Business Intelligence Solutions with Microsoft Azure pass
 
Georgia Azure Event - Scalable cloud games using Microsoft Azure
Georgia Azure Event - Scalable cloud games using Microsoft AzureGeorgia Azure Event - Scalable cloud games using Microsoft Azure
Georgia Azure Event - Scalable cloud games using Microsoft Azure
 
OpenPOWER Roadmap Toward CORAL
OpenPOWER Roadmap Toward CORALOpenPOWER Roadmap Toward CORAL
OpenPOWER Roadmap Toward CORAL
 
OpenPOWER Update
OpenPOWER UpdateOpenPOWER Update
OpenPOWER Update
 
The State of Linux Containers
The State of Linux ContainersThe State of Linux Containers
The State of Linux Containers
 
IBM POWER8 as an HPC platform
IBM POWER8 as an HPC platformIBM POWER8 as an HPC platform
IBM POWER8 as an HPC platform
 
Presentacin webinar move_up_to_power8_with_scale_out_servers_final
Presentacin webinar move_up_to_power8_with_scale_out_servers_finalPresentacin webinar move_up_to_power8_with_scale_out_servers_final
Presentacin webinar move_up_to_power8_with_scale_out_servers_final
 
Bitcoin explained
Bitcoin explainedBitcoin explained
Bitcoin explained
 
Blockchain
BlockchainBlockchain
Blockchain
 
Oracle Solaris Software Integration
Oracle Solaris Software IntegrationOracle Solaris Software Integration
Oracle Solaris Software Integration
 
Open Innovation with Power Systems
Open Innovation with Power Systems Open Innovation with Power Systems
Open Innovation with Power Systems
 
IBM Power8 announce
IBM Power8 announceIBM Power8 announce
IBM Power8 announce
 

Similaire à Puppet + Windows Nano Server

From Dev to DevOps - Codemotion ES 2012
From Dev to DevOps - Codemotion ES 2012From Dev to DevOps - Codemotion ES 2012
From Dev to DevOps - Codemotion ES 2012
Carlos Sanchez
 
Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013
Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013
Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013
Carlos Sanchez
 

Similaire à Puppet + Windows Nano Server (20)

PuppetConf 2016: Nano Server, Puppet, and DSC
PuppetConf 2016: Nano Server, Puppet, and DSCPuppetConf 2016: Nano Server, Puppet, and DSC
PuppetConf 2016: Nano Server, Puppet, and DSC
 
From Dev to DevOps - Codemotion ES 2012
From Dev to DevOps - Codemotion ES 2012From Dev to DevOps - Codemotion ES 2012
From Dev to DevOps - Codemotion ES 2012
 
Agile Brown Bag - Vagrant & Docker: Introduction
Agile Brown Bag - Vagrant & Docker: IntroductionAgile Brown Bag - Vagrant & Docker: Introduction
Agile Brown Bag - Vagrant & Docker: Introduction
 
Bare Metal to OpenStack with Razor and Chef
Bare Metal to OpenStack with Razor and ChefBare Metal to OpenStack with Razor and Chef
Bare Metal to OpenStack with Razor and Chef
 
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
 
How to manage Azure with open source
How to manage Azure with open sourceHow to manage Azure with open source
How to manage Azure with open source
 
How to manage Microsoft Azure with open source
How to manage Microsoft Azure with open sourceHow to manage Microsoft Azure with open source
How to manage Microsoft Azure with open source
 
Dockerizing a Symfony2 application
Dockerizing a Symfony2 applicationDockerizing a Symfony2 application
Dockerizing a Symfony2 application
 
codemotion-docker-2014
codemotion-docker-2014codemotion-docker-2014
codemotion-docker-2014
 
One-Man Ops
One-Man OpsOne-Man Ops
One-Man Ops
 
Postgres the hardway
Postgres the hardwayPostgres the hardway
Postgres the hardway
 
Harmonious Development: Via Vagrant and Puppet
Harmonious Development: Via Vagrant and PuppetHarmonious Development: Via Vagrant and Puppet
Harmonious Development: Via Vagrant and Puppet
 
Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013
Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013
Continuous Delivery with Maven, Puppet and Tomcat - ApacheCon NA 2013
 
From Dev to DevOps
From Dev to DevOpsFrom Dev to DevOps
From Dev to DevOps
 
Docker Ecosystem on Azure
Docker Ecosystem on AzureDocker Ecosystem on Azure
Docker Ecosystem on Azure
 
Delivering Docker & K3s worloads to IoT Edge devices
Delivering Docker & K3s worloads to IoT Edge devicesDelivering Docker & K3s worloads to IoT Edge devices
Delivering Docker & K3s worloads to IoT Edge devices
 
Docker 進階實務班
Docker 進階實務班Docker 進階實務班
Docker 進階實務班
 
Deploying windows containers with kubernetes
Deploying windows containers with kubernetesDeploying windows containers with kubernetes
Deploying windows containers with kubernetes
 
廣宣學堂: 容器進階實務 - Docker進深研究班
廣宣學堂: 容器進階實務 - Docker進深研究班廣宣學堂: 容器進階實務 - Docker進深研究班
廣宣學堂: 容器進階實務 - Docker進深研究班
 
Deploying Windows Containers on Windows Server 2016
Deploying Windows Containers on Windows Server 2016Deploying Windows Containers on Windows Server 2016
Deploying Windows Containers on Windows Server 2016
 

Plus de Alessandro Pilotti

Interoperable OpenStack guest provisioning with Cloudbase-Init
Interoperable OpenStack guest provisioning with Cloudbase-InitInteroperable OpenStack guest provisioning with Cloudbase-Init
Interoperable OpenStack guest provisioning with Cloudbase-Init
Alessandro Pilotti
 
Hyper-V OpenStack Nova Compute
Hyper-V OpenStack Nova ComputeHyper-V OpenStack Nova Compute
Hyper-V OpenStack Nova Compute
Alessandro Pilotti
 

Plus de Alessandro Pilotti (12)

Strategies for migrating workloads from VMware to OpenStack
Strategies for migrating workloads from VMware to OpenStackStrategies for migrating workloads from VMware to OpenStack
Strategies for migrating workloads from VMware to OpenStack
 
OpenStack Summit 2013 Hong Kong - OpenStack and Windows
OpenStack Summit 2013 Hong Kong - OpenStack and WindowsOpenStack Summit 2013 Hong Kong - OpenStack and Windows
OpenStack Summit 2013 Hong Kong - OpenStack and Windows
 
Interoperable OpenStack guest provisioning with Cloudbase-Init
Interoperable OpenStack guest provisioning with Cloudbase-InitInteroperable OpenStack guest provisioning with Cloudbase-Init
Interoperable OpenStack guest provisioning with Cloudbase-Init
 
OpenStack and Windows
OpenStack and WindowsOpenStack and Windows
OpenStack and Windows
 
An HTML5 client to connect to the Hyper-V console
An HTML5 client to connect to the Hyper-V consoleAn HTML5 client to connect to the Hyper-V console
An HTML5 client to connect to the Hyper-V console
 
Hyper-V OpenStack Nova Compute
Hyper-V OpenStack Nova ComputeHyper-V OpenStack Nova Compute
Hyper-V OpenStack Nova Compute
 
Drupal, Memcache and Solr on Windows
Drupal, Memcache and Solr on WindowsDrupal, Memcache and Solr on Windows
Drupal, Memcache and Solr on Windows
 
PHP and FastCGI Performance Optimizations
PHP and FastCGI Performance OptimizationsPHP and FastCGI Performance Optimizations
PHP and FastCGI Performance Optimizations
 
Managing Drupal on Windows with Drush
Managing Drupal on Windows with DrushManaging Drupal on Windows with Drush
Managing Drupal on Windows with Drush
 
Building drupal web farms with IIS - part 1
Building drupal web farms with IIS - part 1Building drupal web farms with IIS - part 1
Building drupal web farms with IIS - part 1
 
Windows Loves drupal
Windows Loves drupalWindows Loves drupal
Windows Loves drupal
 
Building modern web sites with ASP .Net Web API, WebSockets and RSignal
Building modern web sites with ASP .Net Web API, WebSockets and RSignalBuilding modern web sites with ASP .Net Web API, WebSockets and RSignal
Building modern web sites with ASP .Net Web API, WebSockets and RSignal
 

Dernier

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Dernier (20)

EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 

Puppet + Windows Nano Server

  • 1. Windows Nano Server & Puppet Alessandro Pilotti Cloudbase Solutions
  • 3. Agenda Nano Server Puppet on Nano Server Managing resources DSC + Puppet Demos
  • 4. What is Nano Server? A lightweight installation option for Windows Server Optimized for cloud deployments Optimized footprint, a few hundred megabytes! Fast boot times Windows without Windows
  • 5. What can I do with Nano Server? Included Packages Hyper-V Shielded VM Windows Containers (including Docker) File Server (including SoFS / S2D) IIS / ASP.Net 5 Windows Failover Clustering DNS SCVMM DSC Additional Packages OpenStack
  • 6. Availability? Released with Windows Server 2016 Currently available in Technical Preview (TP5) Get a Windows Server 2016 TP5 ISO from: https://microsoft.com/en-us/evalcenter/evaluate-windows-server-technical- preview
  • 7.
  • 8. Limitations Nano Server’s API surface is limited! Includes “reverse forwarders” for compatibility with existing binaries Any API that requires Windows GUI / shell interaction is missing or not implemented Win64 .Net CoreCLR is portable (Windows, Linux, OS X) but more limited compared to the Full CLR
  • 9. Limitations Some CLI differences PowerShell differences No MSI No ADSI (used by puppet for managing users and groups) COM STA mode not available (only MTA) No COM monikers In general porting applications to run on Nano requires some effort
  • 10. How to check application compatibility? Windows API (Native apps, C/C++, etc): NanoServerApiScan.exe .Net Core https://github.com/Microsoft/dotnet-apiport
  • 11. Build a Nano Server image for bare metal or Hyper-V Get a Windows Server 2016 TP5 ISO from https://www.microsoft.com/en-us/evalcenter/evaluate- windows-server-technical-preview Example: Packages can be added (Hyper-V, IIS, etc) Select –DeploymentType Host for physical servers A custom unattend.xml can be provided for apps deployment / configuration No need for activation! New-NanoServerImage -Edition Standard -DeploymentType Guest -MediaPath f: -BasePath .Base -TargetPath .Nano1Nano.vhd -ComputerName Nano1
  • 12. What about OpenStack, KVM, ESXi, MAAS, etc? PowerShell script to add additional features and target formats: https://github.com/cloudbase/cloudbase-init-offline-install ..NewNanoServerImage.ps1 -IsoPath C:WindowsServerTP5.iso ` -TargetPath C:Nano.qcow2 -Platform KVM ` -AdministratorPassword $password ` -Compute -Storage -Clustering ` -ExtraDriversPaths C:DevDriversNUC_2015_Intel_ndis64 ` -AddCloudbaseInit ` -AddMaaSHooks ` -MaxSize 1500MB ` -DiskLayout "BIOS"
  • 13. Managing Nano Server On a Hyper-V host: PowerShell remoting is available also on regular Windows! This is the native equivalent of SSH on Windows How to copy files remotely: $c = Get-Credential Enter-PSSession <NanoServer> -Credential $c Enter-PSSession –VMName <NanoServerVMName> -Credential $c $s = New-PSSession <NanoServer> -Credential $c Copy –ToSession $s –Path c:SomeFiles –Destination c:SomeRemoteDir
  • 14. Install packages Windows equivalent of apt-get find-packageprovider find-package -provider nuget -source http://www.nuget.org/api/v2 install-package node.js -destination c:node -provider nuget -source http://www.nuget.org/api/v2
  • 15. OpenStack + Nano Server https://cloudbase.it/openstack-windows-nano-server/ Cloudbase-Init support → Including Heat templates support Works on OpenStack supported hypervisors: → Hyper-V → KVM → ESXi
  • 16.
  • 17. Add packages at runtime Install-PackageProvider NanoServerPackage Find-NanoServerPackage -name * Find-NanoServerPackage Microsoft-NanoServer-IIS-Package | ` Install-NanoServerPackage -culture en-us
  • 18. Create a Nano Server instance
  • 19. Offline domain join No need to share sensitive domain credentials! On a domain joined host: Copy blob.txt to the host that needs to join the domain and run: Works on Windows Server 2008 R2 and above as well! djoin /provision /domain cloudbase.demo /machine nanotp5 /savefile blob.txt djoin /requestODJ /loadfile blob.txt /windowspath %SystemRoot% /localos
  • 20. Puppet on Nano Server Puppet is based on Ruby 2.x and C++ Ruby works on Nano Server with some minor changes: Win32ole win32-dir Facter needs also minor changes (both Ruby and native ones) Some resource types do not work ATM, e.g. users and groups Other providers require minor changes, e.g.: Puppetlabs-dsc Puppetlabs-reboot
  • 21. How to create packages on Nano Server MSI are not supported on Nano Server Nano Server has a new packaging model called Windows Server Apps (WSA) based on APPX Packages include a directory tree and some extensions: NT services, WMI providers, COM servers An XML manifest file is needed Appx packages need to be signed Deployment:Add-AppxPackage puppet.appx Get-AppxPackage puppet Remove-AppxPackage puppet
  • 22. A Puppet APPX package Here’s a Puppet for Nano Server package: https://github.com/cloudbase/puppet-nano-server For creating the package, you need the latest Windows 10 SDK (10.0.14332.1000 or above) The certificate CN must match the publisher’s identity in the certificate makeappx pack /d puppet-nano-server /p puppet.appx signtool.exe sign /fd sha256 /sha1 xxxxxxxxxxxxxxxxxxxxx /t http://timestamp.verisign.com/scripts/timstamp.dll /v puppet.appx
  • 23. Puppet and Nano Server Some notable modules: puppetlabs-powershell puppetlabs-acl puppetlabs-reboot puppetlabs-dsc Some widely used Windows modules and resource types don’t work, e.g.: puppet-iis is based on the PowerShell WebAdministration module (Not available on Nano) scheduled_task requires mstask.dll, not available on Nano Server
  • 24. How to manage local users and groups ADSI is not supported on Nano, so until Puppet will add an alternative (e.g. Win32): $username = 'nano' $password = 'P@ssw0rd' $groupname = 'puppet' exec { 'new-local-group': command => "New-LocalGroup -Name ${groupname}", unless => "Get-LocalGroup -Name ${groupname}", provider => powershell, }
  • 25. How to manage local users and groups exec { 'new-local-user': command => "New-LocalUser -Name ${username} –Password (ConvertTo-SecureString -AsPlainText "${password}" -Force) -PasswordNeverExpires", unless => "Get-LocalUser -Name ${username}", provider => powershell, } exec { 'add-local-group-member': command => "Add-LocalGroupMember -Group ${groupname} -Member ${username}", unless => "Get-LocalGroupMember -Group ${groupname} -Member ${username}", provider => powershell, require => [Exec['new-local-group'], Exec['new-local-user']], }
  • 26. DSC and Puppet PowerShell Distributed State Configuration (DSC) DSC is a declarative platform used for configuration, deployment, and management of systems Similar in scope to Puppet The puppetlabs-dsc module offers a bridge between puppet and DSC Allows to use DSC resources, no need to rewrite them for Puppet Only a few resources work on Nano for the time being (technical preview) Notice the dsc_ prefix dsc_registry {'registry_test': dsc_ensure => 'Present', dsc_key => 'HKEY_LOCAL_MACHINESOFTWAREExampleKey', dsc_valuename => 'TestValue', dsc_valuedata => 'TestData',
  • 27. Demo
  • 28. Licensing Windows licensing is surprisingly easy in OpenStack → Datacenter license => unlimited instances → 1 license per socket => per core in 2016 → Works with Hyper-V, VMWare, KVM, etc → Very cost effective (a few USD / month per VM) Volume licensing Multitenant? SPLA
  • 29. Q&A

Notes de l'éditeur

  1. OpenStack: Developers and maintainers of the Windows / Hyper-V related features
  2. And here’s how it looks like!