GithubHelp home page GithubHelp logo

mboersma / azure-powershell Goto Github PK

View Code? Open in Web Editor NEW

This project forked from azure/azure-powershell

0.0 2.0 0.0 800.19 MB

Microsoft Azure PowerShell

License: Other

Dockerfile 0.01% PowerShell 17.93% C# 82.02% Batchfile 0.03% Ruby 0.01% XSLT 0.01% Smalltalk 0.01% JavaScript 0.01% Shell 0.01% HTML 0.01% PHP 0.01%

azure-powershell's Introduction

Microsoft Azure PowerShell

This repository contains a set of PowerShell cmdlets for developers and administrators to develop, deploy and manage Microsoft Azure applications.

Take a test run now from Azure Cloud Shell!

Modules

Below is a table containing the various Azure PowerShell rollup modules found in this repository. For a full list of modules found in this repository, please see the Azure PowerShell Modules page.

Description Module Name PowerShell Gallery Link
Rollup Module for Az cmdlets Az Az
Rollup Module for Administrative Modules in Azure Stack AzureStack AzureStack
Rollup Module for Service Management Cmdlets Azure Azure

Installation

For more detailed instructions on installing Azure PowerShell, please refer to the installation guide.

PowerShell Gallery

Run the following command in an elevated PowerShell session to install the new 'Az' module for ResourceManager cmdlets. This module runs on PowerShell 5.1 (with .Net Framework 4.7.2) , or PowerShell Core, and replaces AzureRM. You should not install this module side-by-side with AzureRM:

Install-Module -Name Az

To install the module containing the legacy RDFE cmdlets, run the following command in an elevated PowerShell session:

Install-Module -Name Azure

If you have an earlier version of the Azure PowerShell modules installed from the PowerShell Gallery and would like to update to the latest version, run the following commands in an elevated PowerShell session. Update-Module installs the new version side-by-side with the old version. It does not remove the old version.

# Update to the latest version of Az
Update-Module -Name Az

# Update to the latest version of Azure
Update-Module -Name Azure

Web Platform Installer

Download and install the Microsoft Web Platform Installer. Once installed, open the program and search for Microsoft Azure PowerShell. Click the Add button followed by the Install button at the bottom to begin the installation process.

Usage

For more detailed instructions on using Azure PowerShell, please refer to the getting started guide.

Log in to Azure

To connect to Azure, use the Connect-AzAccount cmdlet.

# Interactive login - you will get a dialog box asking for your Azure credentials
Connect-AzAccount

# Non-interactive login - you will need to use a service principal
Connect-AzAccount -ServicePrincipal -ApplicationId "http://my-app" -Credential $PSCredential -TenantId $TenantId

To log into a specific cloud (AzureChinaCloud, AzureCloud, AzureGermanCloud, AzureUSGovernment), use the Environment parameter:

# Log into a specific cloud - in this case, the Azure China cloud
Connect-AzAccount -Environment AzureChinaCloud

Getting and setting your session context

To view the context you are using in the current session, which contains the subscription and tenant, use the Get-AzContext cmdlet:

# Get the context you are currently using
Get-AzContext

# List all available contexts in the current session
Get-AzContext -ListAvailable

To get the subscriptions in a tenant, use the Get-AzSubscription cmdlet:

# Get all of the subscriptions in your current tenant
Get-AzSubscription

# Get all of the subscriptions in a specific tenant
Get-AzSubscription -TenantId $TenantId

To change the subscription that you are using for your current context, use the Set-AzContext cmdlet:

# Set the context to a specific subscription
Set-AzContext -Subscription $SubscriptionName -Name "MyContext"

# Set the context using piping
Get-AzSubscription -SubscriptionName $SubscriptionName | Set-AzContext -Name "MyContext"

Discovering cmdlets

Use the Get-Command cmdlet to discover cmdlets within a specific module, or cmdlets that follow a specific search pattern:

# View all cmdlets in the AzureRM.Profile module
Get-Command -Module Az.Profile

# View all cmdlets that contain "VirtualNetwork"
Get-Command -Name "*VirtualNetwork*"

# View all cmdlets that contain "VM" in the AzureRM.Compute module
Get-Command -Module Az.Compute -Name "*VM*"

Cmdlet help and examples

To view the help content for a cmdlet, use the Get-Help cmdlet:

# View the basic help content for Get-AzSubscription
Get-Help -Name Get-AzSubscription

# View the examples for Get-AzSubscription
Get-Help -Name Get-AzSubscription -Examples

# View the full help content for Get-AzSubscription
Get-Help -Name Get-AzSubscription -Full

# View the help content for Get-AzSubscription on https://docs.microsoft.com
Get-Help -Name Get-AzSubscription -Online

Reporting Issues and Feedback

Issues

If you find any bugs when using the Azure PowerShell modules, please file an issue here, making sure to fill out the provided template with the appropriate information.

Alternatively, be sure to check out the Azure Support Community if you have trouble with any of the cmdlets or Azure services.

Feedback

If there is a feature you would like to see in Azure PowerShell, please use the Send-Feedback cmdlet, or file an issue here, to send the team direct feedback.

Contribute Code

If you would like to become an active contributor to this project please follow the instructions provided in Microsoft Azure Projects Contribution Guidelines.

More information about contributing to this repo can be found in CONTRIBUTING md and the Azure PowerShell Developer Guide folder.

Learn More


This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

azure-powershell's People

Contributors

azdevxps avatar bganapa avatar blueww avatar brnleehng avatar cormacpayne avatar darshanhs90 avatar deathly809 avatar deepakswifty avatar dihan0604 avatar emmazhu avatar eshaparmar avatar evgenyagafonchikov avatar gucalder avatar huangpf avatar hyonholee avatar markcowl avatar miyanni avatar mkherani avatar neharaje avatar ogail avatar pikumarmsft avatar pragrawa avatar praries880 avatar safeermohammed avatar sergey-shandar avatar sriramvu avatar stankovski avatar vivsriaus avatar yaakoviyun avatar yoavrubin avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.