{"id":162,"date":"2019-04-14T15:01:03","date_gmt":"2019-04-14T13:01:03","guid":{"rendered":"https:\/\/gerardmoullec.wordpress.com\/?p=162"},"modified":"2019-04-14T15:01:03","modified_gmt":"2019-04-14T13:01:03","slug":"piloter-une-infra-azure-avec-powershell-2","status":"publish","type":"post","link":"https:\/\/gmitconsult.com\/?p=162","title":{"rendered":"Pilotez une Infra Azure avec Powershell"},"content":{"rendered":"<p>Le livre Automating-Microsoft-Azure-With-Powershell d\u00e9crit les \u00e9tapes permettant la mise en place et le suivi d&rsquo;un infra Microsoft Azure en 10 chapitres et 280 pages.<\/p>\n<p>https:\/\/fr.scribd.com\/read\/272075006\/Automating-Microsoft-Azure-with-PowerShell?mode=standard#<\/p>\n<p>Ci-joint quelques exemples de ce livre 100 % technique :<\/p>\n<h3>Chapitre 1 : Outils pour azure powershell<\/h3>\n<p>Se connecter \u00e0 Azure :<\/p>\n<p><strong>Add-AzureAccount<\/strong><\/p>\n<h3>Chapitre 2 : Gestion des comptes de stockage<\/h3>\n<p><strong>$accountKey = Get-AzureStorageKey -StorageAccountName psautomation<\/strong><br \/>\n<strong>$accountKey | Format-List \u2013Property Primary,Secondary)<\/strong><\/p>\n<h3>Chapitre 3 : Gestion des machines virtuelles<\/h3>\n<p>Voir les machines qui ont Windows Server 2012 :<\/p>\n<p><strong>Get-AzureVMImage | Where-Object { $_.Label -Match \u00ab\u00a0Windows Server 2012 R2 Data- center\u00a0\u00bb } | Format-List -Property ImageName,Label<\/strong><\/p>\n<h3>Chapitre 4 : Cr\u00e9ation d&rsquo;une base de donn\u00e9es SQL<\/h3>\n<p>Acc\u00e8s \u00e0 la base :<\/p>\n<p><strong>$credentials = Get-Credential<\/strong><br \/>\n<strong>$context = New-AzureSqlDatabaseServerContext -ServerName \u00ab\u00a0server01\u00a0\u00bb -Credential $credentials<\/strong><br \/>\n<strong>New-AzureSqlDatabase \u2013ConnectionContext $context \u2013DatabaseName \u00ab\u00a0MyDatabase\u00a0\u00bb<\/strong><\/p>\n<h3>Chapitre 5 : Gestion Web<\/h3>\n<p>Voir le site web :<\/p>\n<p><strong>Get-AzureWebsite<\/strong><\/p>\n<h3>Chapitre 6 : Gestion des r\u00e9seaux<\/h3>\n<p>Voir les r\u00e9seaux VNet :<\/p>\n<p><strong>Get-AzureVNetSite<\/strong><\/p>\n<h3>Chapitre 7 : Cr\u00e9ation d&rsquo;une analyse de flux dans traffic Web<\/h3>\n<p>Cr\u00e9ation d&rsquo;une r\u00e9gle du flux :<\/p>\n<p><strong>New-AzureTrafficManagerProfile \u2013Name \u00ab\u00a0psautomation\u00a0\u00bb \u2013DomainName \u00ab\u00a0psautomation.trafficmanager.net\u00a0\u00bb \u2013LoadBalancingMethod \u00ab\u00a0Failover\u00a0\u00bb \u2013Ttl 30 \u2013MonitorProtocol \u00ab\u00a0Http\u00a0\u00bb \u2013MonitorPort 80 \u2013MonitorRelativePath \u00ab\u00a0\/\u00a0\u00bb<\/strong><\/p>\n<h3>Chapitre 8 : Gestion des services<\/h3>\n<p>Voir les services :<\/p>\n<p><strong>Get-AzureService<\/strong><\/p>\n<h3>Chapitre 9 : Manager Azure Active Directory<\/h3>\n<p>Voir les membres d&rsquo;un groupe :<\/p>\n<p><span id=\"autogen_id_365980883\" class=\"react_mount_node\"><span class=\"text_line\"><strong>Get-MsolGroupMember -GroupObjectId $services.ObjectId<\/strong><strong>\u00a0<\/strong> <\/span><\/span><\/p>\n<h3>Chapitre 10 : Automatiser des taches dans Azure<\/h3>\n<p>Cr\u00e9ation d&rsquo;un compte pour automatiser des taches :<\/p>\n<p><span id=\"autogen_id_365980883\" class=\"react_mount_node\"><strong><span class=\"text_line\">New-AzureAutomationRunbook \u2013Name \u00ab\u00a0PSAutomationStarter\u00a0\u00bb \u2013AutomationAccountName\u00a0 <\/span><\/strong><span class=\"text_line\"><strong>psautomation<\/strong><strong>\u00a0<\/strong> <\/span><\/span><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Le livre Automating-Microsoft-Azure-With-Powershell d\u00e9crit les \u00e9tapes permettant la mise en place et le suivi d&rsquo;un infra Microsoft Azure en 10 chapitres et 280 pages. https:\/\/fr.scribd.com\/read\/272075006\/Automating-Microsoft-Azure-with-PowerShell?mode=standard# Ci-joint quelques exemples de ce livre 100 % technique : Chapitre 1 : Outils pour azure powershell Se connecter \u00e0 Azure : Add-AzureAccount Chapitre 2 : Gestion des comptes de&hellip; <a class=\"more-link\" href=\"https:\/\/gmitconsult.com\/?p=162\">Continue reading <span class=\"screen-reader-text\">Pilotez une Infra Azure avec Powershell<\/span> <span class=\"meta-nav\" aria-hidden=\"true\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":170,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/gmitconsult.com\/index.php?rest_route=\/wp\/v2\/posts\/162"}],"collection":[{"href":"https:\/\/gmitconsult.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gmitconsult.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gmitconsult.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/gmitconsult.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=162"}],"version-history":[{"count":0,"href":"https:\/\/gmitconsult.com\/index.php?rest_route=\/wp\/v2\/posts\/162\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/gmitconsult.com\/index.php?rest_route=\/wp\/v2\/media\/170"}],"wp:attachment":[{"href":"https:\/\/gmitconsult.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=162"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gmitconsult.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=162"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gmitconsult.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=162"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}