Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for deploying PowerShell modules from the gallery (and not using a uri) in azurerm_automation_module #20922

Open
1 task done
humanascode opened this issue Mar 13, 2023 · 1 comment

Comments

@humanascode
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Community Note

  • Please vote on this issue by adding a 馃憤 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

Currently, the only way to deploy and manage PowerShell modules in Azure Automation is to supply a URI. The portal lets you choose a module from the modules gallery. Thhis make managing modules complicated as you have to download the module and upload it to your own storage account and repeat the process every time a new version comes out.

New or Affected Resource(s)/Data Source(s)

azurerm_automation_module

Potential Terraform Configuration

resource "azurerm_automation_module" "msGraphModule" {
  name = "Microsoft.Graph.Users"
  automation_account_name = azurerm_automation_account.aa.name
  resource_group_name = azurerm_resource_group.rg.name
  installation_source {
    module_source = "Gallery"
    gallery_module_name = "Microsoft.Graph"
    module_verion = "latest"
  }
}

References

No response

@humanascode humanascode changed the title Support for deploying PowerShell modules from the gallery (and not using a uri) Support for deploying PowerShell modules from the gallery (and not using a uri) in azurerm_automation_module Mar 13, 2023
@wuxu92
Copy link
Contributor

wuxu92 commented Mar 16, 2023

Hi @itamar56 thanks for you feedback, i believe this feature request is very much reasonable. but for now, the gallery modules cannot managed by terraform and there isn't such API fot azurerm to featch the gallery module list.

to simplify your operation to use the gallery module, you can use browser devtools to find the link of gallery modules in this API https://s2.automation.ext.azure.com/api/Orchestrator/GalleryModuleItems?pageLink=&filter=&orderBy=1 (open it in browset when logged in portal) . change the filter value if you want to query by module name.

you can use this link to deploy the automation module:

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants