Created
November 20, 2017 11:33
-
-
Save Staggerlee011/9aae7e18cc3b2228eb1156dc9981ec87 to your computer and use it in GitHub Desktop.
Collection of Chef Test-Kitchen commands by example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## list kitchen test state | |
kitchen list | |
## creates vm based on kitchen.yml | |
kitchen create | |
## applies cookbook to vm | |
kitchen converge | |
## kitchen verify runs tests from folder: | |
kitchen verify | |
## test (destory -> create -> converge -> verify -> destory) | |
kitchen test | |
## rdp - if not specificing in driver_config then it uses azure/P2ssw0rd for login/password | |
kitchen login | |
## example calling the vm | |
kitchen exec -c '(Invoke-WebRequest -UseBasicParsing localhost).Content' | |
kitchen exec -c 'Get-Acl c:\inetpub\wwwroot\Default.htm | Format-List' | |
kitchen exec -c 'Get-DscLocalConfigurationManager | select -ExpandProperty "ConfigurationMode"' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment