Automating Microsoft Azure Infrastructure Services.pdf

(5849 KB) Pobierz
Automating
Microsoft Azure
Infrastructure
Services
FROM THE DATA CENTER TO THE CLOUD WITH POWERSHELL
Foreword by Mark Russinovich
www.it-ebooks.info
Michael Washam
Automating Microsoft Azure Infrastructure Services
Get valuable tips and techniques for automating your cloud deployments
with Azure PowerShell cmdlets, and learn how to provision Azure services
on the fly. In this hands-on guide, Microsoft cloud technology expert
Michael Washam shows you how to automate various management tasks
and deploy solutions that are both complex and at scale.
By combining the native automation capabilities of PowerShell with Azure
Infrastructure Services, these powerful cmdlets enable you to create and
configure virtual machines with ease. You’ll learn how to take advantage
of these technologies to build complete virtual networks. If you have
experience with PowerShell and Azure, you’re ready to get started.
This book is the
definitive overview
and deep reference on
using Microsoft Azure’s
PowerShell cmdlets
to automate Microsoft
Azure Infrastructure
Services.
Install and authenticate cmdlets to set up your environment
Create and update virtual machines with Azure platform
images
Manage network endpoints, access control lists, and IP
addresses
Use cmdlets to manage and configure virtual machine storage
Automate Azure virtual networks with hybrid technologies
such as site-to-site, point-to-site, and ExpressRoute
Dive into advanced virtual machine provisioning capabilities
and management techniques
Learn tips and tricks for deleting or moving virtual machines
within (or out of) your subscription
Chief Technical Officer, Microsoft Azure
—Mark Russinovich
Michael Washam
is cofounder and CEO of Opsgility, a company that delivers
instructor-led, remote-classroom and on-demand training for Microsoft cloud
technologies. At Microsoft, Michael led the release of the Azure PowerShell
cmdlets for compute and the Azure SDK, and worked on the initial Azure
Infrastructure-as-a-Service launch.
POWER SHELL/ WINDOWS
Twitter: @oreillymedia
facebook.com/oreilly
US $29.99
CAN $31.99
ISBN: 978-1-491-94489-9
www.it-ebooks.info
Automating Microsoft Azure
Infrastructure Services
Michael Washam
www.it-ebooks.info
Automating Microsoft Azure Infrastructure Services
by Michael Washam
Copyright © 2015 Opsgility, LLC. All rights reserved.
Printed in the United States of America.
Published by O’Reilly Media, Inc., 1005 Gravenstein Highway North, Sebastopol, CA 95472.
O’Reilly books may be purchased for educational, business, or sales promotional use. Online editions are
also available for most titles (http://safaribooksonline.com). For more information, contact our corporate/
institutional sales department: 800-998-9938 or
corporate@oreilly.com.
Editors:
Rachel Roumeliotis and Allyson MacDonald
Production Editor:
Matthew Hacker
Copyeditor:
Sonia Saruba
Proofreader:
Sharon Wilkey
November 2014:
First Edition
Indexer:
Wendy Catalano
Cover Designer:
Ellie Volckhausen
Interior Designer:
David Futato
Illustrator:
Rebecca Demarest
Revision History for the First Edition:
2014-10-17:
First release
See
http://oreilly.com/catalog/errata.csp?isbn=9781491944899
for release details.
The O’Reilly logo is a registered trademark of O’Reilly Media, Inc.
Automating Microsoft Azure Infrastructure
Services,
the cover image of a saltwater crocodile, and related trade dress are trademarks of O’Reilly
Media, Inc.
Many of the designations used by manufacturers and sellers to distinguish their products are claimed as
trademarks. Where those designations appear in this book, and O’Reilly Media, Inc. was aware of a trademark
claim, the designations have been printed in caps or initial caps.
While the publisher and the author have used good faith efforts to ensure that the information and instruc‐
tions contained in this work are accurate, the publisher and the author disclaim all responsibility for errors
or omissions, including without limitation responsibility for damages resulting from the use of or reliance
on this work. Use of the information and instructions contained in this work is at your own risk. If any code
samples or other technology this work contains or describes is subject to open source licenses or the intel‐
lectual property rights of others, it is your responsibility to ensure that your use thereof complies with such
licenses and/or rights.
ISBN: 978-1-491-94489-9
[LSI]
www.it-ebooks.info
Table of Contents
Foreword. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii
Preface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ix
1. Introduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Why Use the Microsoft Azure PowerShell Cmdlets?
Comparing Deployment Methods
Deploying an Application in a Traditional Data Center
Deploying an Application in the Cloud (Without Automation)
Deploying an Application in the Cloud (with Automation)
History
Open Source
Summary
Installation
Setting Up Your Environment
Authenticating to Microsoft Azure
Managing Subscriptions
Executing Scripts in This Book
Summary
1
2
2
2
2
3
4
4
2. Getting Started with Azure PowerShell. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
5
5
6
8
10
11
13
14
17
18
19
20
22
3. Virtual Machines. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Creating Virtual Machines with PowerShell
Virtual Machine Location and Storage
Selecting the Virtual Machine Platform Image
Virtual Machine Size
Cloud Services and Virtual Machines
Creating a Virtual Machine with New-AzureQuickVM
Creating a Virtual Machine Configuration with New-AzureVMConfig
iii
www.it-ebooks.info
Zgłoś jeśli naruszono regulamin