LoginSignup
1
1

More than 3 years have passed since last update.

Ansible:Ansibleでwindowsマシンを操作する~準備編~

Last updated at Posted at 2019-07-30

WindowsModule一覧

対象マシン

WindowsServer2016

Windowsに対してリモート接続できるようにポリシー変更

PowerShellは管理者権限で起動すること

ps
PS C:> Get-ExecutionPolicy
PS C:>Set-ExecutionPolicy RemoteSigned

Ansibleで操作できるようにするスクリプト実行

コマンドでgitから取得する

ps
PS C:\> mkdir C:\work
PS C:\> cd .\work
PS C:\work> Invoke-WebRequest -Uri https://raw.githubusercontent.com/ansible/ansible/devel/examples/scripts/ConfigureRemotingForAnsible.ps1 -OutFile ConfigureRemotingForAnsible.ps1
PS C:\work> powershell.exe .\ConfigureRemotingForAnsible.ps1

プロキシが刺さっていたら反映する

ps
netsh winhttp import proxy source=ie

終わり

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1