Skip to content

Commit

Permalink
Merge pull request #1326 from DannyBrito/dannybrito/add-az-in-windows…
Browse files Browse the repository at this point in the history
…-img

add az-cli for capz windows images
  • Loading branch information
k8s-ci-robot authored Oct 23, 2023
2 parents 8711be9 + bebac69 commit d344be8
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
15 changes: 15 additions & 0 deletions images/capi/ansible/windows/roles/providers/tasks/azure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,18 @@
members: "{{ users }}"
vars:
users: "{{ wire_server_users.split(',') if (wire_server_users is defined) and (wire_server_users | length > 0) else [] }}"

- name: Download Azure CLI MSI installer
ansible.windows.win_get_url:
url: https://aka.ms/installazurecliwindowsx64
dest: C:\azure-cli.msi

- name: Install Azure CLI
ansible.windows.win_package:
path: C:\azure-cli.msi
state: present

- name: Clean up Azure CLI Installer file
ansible.windows.win_file:
path: C:\azure-cli.msi
state: absent
3 changes: 3 additions & 0 deletions images/capi/packer/goss/goss-command.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,9 @@ command:
stdout:
- "ICcgDomainAuthCredentials"
timeout: 30000
Check Azure CLI is installed via alias:
exec: powershell -command "az"
exit-status: 0
{{end}}

{{ if ne .Vars.ssh_source_url "" }}
Expand Down

0 comments on commit d344be8

Please sign in to comment.