Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
PowerShellの ”これまで” と ”これから” ~ 若干のAzure要素を添えて ~
Search
Takuya Shibata
PRO
December 01, 2018
Technology
0
950
PowerShellの ”これまで” と ”これから” ~ 若干のAzure要素を添えて ~
JAZUG札幌支部(きたあず) 第21回勉強会で発表した内容です。
Takuya Shibata
PRO
December 01, 2018
Tweet
Share
More Decks by Takuya Shibata
See All by Takuya Shibata
アップデート紹介:AWS Data Transfer Terminal
stknohg
PRO
0
360
CloudFrontの継続的デプロイを試してみたはなし
stknohg
PRO
0
1.3k
Snapshot & Backup
stknohg
PRO
0
3.8k
AWSエンジニアのためのActive Directory入門
stknohg
PRO
1
3k
EC2 Image Builder
stknohg
PRO
0
440
Windows on AWS の “基礎”
stknohg
PRO
0
740
Azure Dedicated Host と2019年10月1日からのライセンス改定のはなし
stknohg
PRO
0
480
Windows on AWS 入門
stknohg
PRO
0
540
普通の人が普通にブログを継続するためにやっていること
stknohg
PRO
0
750
Other Decks in Technology
See All in Technology
シンプルな設定ファイルで実現する AWS IAM Identity Center のユーザー管理と開発チームへの委譲 / Delegating AWS IAM Identity Center User Management with a Simple DSL
yamaguchitk333
3
490
“⾞が通れるほど⼤きな”セキュリティーホールを抑えながらログインしたい
taiseiue
0
130
SmartHRの複数のチームにおけるMCPサーバーの活用事例と課題
yukisnow1823
2
990
継続戦闘能⼒
sansantech
PRO
0
190
ゴリラ.vim #36 ~ Vim x SNS ~ スポンサーセッション
yasunori0418
1
200
Machine Intelligence for Vision, Language, and Actions
keio_smilab
PRO
0
330
FastMCPでSQLをチェックしてくれるMCPサーバーを自作してCursorから動かしてみた
nayuts
0
110
プラットフォームとしての Datadog / Datadog as Platforms
aoto
PRO
1
300
OSMnx Galleryの紹介
mopinfish
0
130
Postman AI エージェントビルダー最新情報
nagix
0
140
TerraformとGitHub Actionsで手軽に実装するECSのCI/CD
k___tkg
0
230
名刺メーカーDevグループ 紹介資料
sansan33
PRO
0
730
Featured
See All Featured
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
331
21k
KATA
mclloyd
29
14k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
19
1.2k
Building Applications with DynamoDB
mza
95
6.4k
Building Adaptive Systems
keathley
41
2.6k
How STYLIGHT went responsive
nonsquared
100
5.6k
We Have a Design System, Now What?
morganepeng
52
7.6k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
29
1.7k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
50k
Adopting Sorbet at Scale
ufuk
76
9.4k
Transcript
PowerShellの ”これまで” と ”これから” ~ 若干のAzure要素を添えて ~ 2018.12.01 JAZUG札幌支部(きたあず) 第21回勉強会
Takuya Shibata
自己紹介 しばた (a.k.a. 素敵なおひげ) Blog : https://blog.shibata.tech/ Twitter : @stknohg
CLR/H と きたあず の裏方をやってます 明日まで無職 Microsoft MVP for Cloud and Datacenter Management (2016.07 - ) 2
宣伝 3
はじめに 30分のセッションなので機能の詳細には触れません。 「PowerShellは何のためのツールなのか?」 という点に絞った話をします。 あと、きたあずなのでAzure PowerShellの話を少し します。 4 きたあずちゃん
PowerShellのこれまで 5
PowerShell? とりあえずの理解 6
(これまでの)PowerShellとは 以前の登壇資料より ※現在この記述はありません 7
(これまでの)PowerShellとは シェル スクリプト言語 Windows Management Framework(WMF) の一部 8 Windows の
管理 と 自動化
PowerShellの歴史 2006 2006年11月、PowerShell 1.0リリース ・・・ ・・・中略・・・ 2016 2016年8月、GitHubにオープンソースとして公開される • 公開時の最新リリースは
PowerShell 6.0 Alpha 9 2018 2018年1月、PowerShell Core 6.0リリース • WindowsだけではなくLinuxやmacOSで動作するクロスプラットフォームなアプリケーションに 2018 2018年9月、PowerShell Core 6.1リリース • 2018年12月現在、最新バージョンは 6.1.1 9
10 PowerShellの歴史 PowerShell 1.0 PowerShell 6.0 Desktop Edition Core Edition
PowerShell 5.1 Editionなし Windows Linux Mac PowerShell 6.1 Core Edition Core Edition Core Edition Core Edition Core Edition Core Edition
2つのPowerShell 11 Windows PowerShell (powershell.exe) ✓PowerShell 1.0 ~5.1 ✓Desktop Edition
✓Windows専用 ✓.NET Framework PowerShell Core (pwsh.exe / pwsh) ✓PowerShell 6.0 ~ 6.1 ✓Core Edition ✓Windows, Linux, macOS ✓.NET Core ※1 厳密にはNano Server向けのPowerShell 5.1もPowerShell Coreに含まれるのですが、ここではわかりやすさのために除外しています ※1
None
PowerShellのこれから 13
(いまの)PowerShellとは 14 https://docs.microsoft.com/ja-jp/powershell/scripting/powershell-scripting より
(いまの)PowerShellとは シェル スクリプト言語 Windows Management Framework(WMF) の一部 15 あらゆるインフラ の
管理 と 自動化
これからのPowerShellにおける”管理” Windowsだけではなくあらゆるインフラの管理基盤を 目指している 「PowerShell for every system!」 目下各種パブリッククラウド、仮想化基盤への対応が中心 Microsoftが、というよりは各ベンダーやコミュニティの動きを見て の私見
LinuxやmacOS単体マシンの管理は正直微妙… OSの管理方法の違い PowerShellを使う必然性の低さ コミュニティよる積み上げがまだ無い 16
17 Azure : Azure PowerShell ✓ https://docs.microsoft.com/ja-jp/powershell/azure/overview AWS : AWS
Tools for PowerShell ✓ https://aws.amazon.com/jp/powershell/ Azure Stack : PowerShell for Azure Stack ✓ https://docs.microsoft.com/ja-jp/azure/azure-stack/azure-stack-powershell-install Google Cloud : CLOUD TOOLS FOR POWERSHELL ✓ https://cloud.google.com/powershell/ VMware : PowerCLI ✓ https://code.vmware.com/web/dp/tool/vmware-powercli/
18 Digital Transformation ここ最近のカンファレンスでのキーワード
https://www.youtube.com/watch?v=zy4fDSdrM7M
https://github.com/psconfeu/2018/blob/master/Jeffrey%20Snover/Keynote_psconfeu_2018.pdf
https://github.com/psconfeu/2018/blob/master/Jeffrey%20Snover/Keynote_psconfeu_2018.pdf
これからのPowerShellにおける”自動化” デジタルトランスフォーメーションを実現するための 自動化 Windowsだけの時代ではない PowerShell Team曰く「ヘテロジニアスな世界に対応する。」 デジタルトランスフォーメーション、とは? Microsoftの見ているものと我々の見ているものは異なるかも? PowerShellでなければならないということではない 22
Azure と PowerShell ※2018.12.01時点での情報となります 23
2つのAzure PowerShell 24 Azure Service Management (Azure) Cloud Service 旧ポータル
Azure.* モジュール Azureプリフィックス .NET Core対応なし Azure Resource Manager (AzureRm / AzureRm.NetCore) Resource Manager 現ポータル AzureRm.* モジュール AzureRmプリフィックス .NET Core対応あり
これからの “Az” モジュール AzureRm、AzureRm.NetCoreモジュールを統合 Windows PowerShell 5.1 と PowerShell Core
6.0 ~ 6.1で動作 モジュール名は AzureRM.* から Az.* に コマンドレット名のプリフィックスが AzureRm から Az に 25 # 例えば Connect-AzureRmAccount なら Connect-AzAccount Connect-AzAccount # Azの各種モジュールを検索 Get-Module -Name Az* -ListAvailable
これからの “Az” モジュール 互換性維持のための Enable-AzureRmAlias / Disable-AzureRmAlias 26 # Enable-AzureRmAlias
で従来のコマンドレット名をエイリアスに追加 Enable-AzureRmAlias # Disable-AzureRmAlias で追加したエイリアスを削除 Disable-AzureRmAlias # -Module指定で対象モジュールを選択、-Scope指定で設定を永続化 Enable-AzureRmAlias -Module Az.Websites -Scope CurrentUser
Azure Cloud Shell 27
Azure Cloud Shell 28
29 Azure Cloud Shell 右図は https://azure.microsoft.com/ja-jp/blog/powershell-comes-to-azure-cloud-shell/ より
Azure Cloud Shell ポータルにあるアレ ブラウザ上のシェル https://shell.azure.com/ Docsやスマートフォンアプリでも使える シェルの利用料金は無料 データの永続化に5GBのVHDを使用するためその費用はかかる Bash
か PowerShell Core を選択可能 どちらもUbuntuコンテナが実体 PowerShellには “Az” モジュールがインストール済み Clould Shell独自のモジュール(PSCloudShellUtility)もある 30
まとめ 31
これからのPowerShellが目指すところ 1. “管理”ツールとしてのPowerShell クロスプラットフォームなインフラ管理 2. “自動化”ツールとしてのPowerShell デジタルトランスフォーメーションの実現 32
Azure PowerShell Azure PowerShellはこれまでの AzureRm / AzureRm.NetCore モジュールから Az モジュールへ
33 Az AzureRm AzureRm.NetCore
Thank You!