{"id":20657730,"url":"https://github.com/boltops-tools/azure_info","last_synced_at":"2025-07-22T11:03:48.852Z","repository":{"id":45253321,"uuid":"269155388","full_name":"boltops-tools/azure_info","owner":"boltops-tools","description":"Azure info: Simple library to get current subscription, resource group, and location, etc","archived":false,"fork":false,"pushed_at":"2021-12-27T22:20:21.000Z","size":26,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-17T15:55:33.595Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/boltops-tools.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-06-03T17:45:15.000Z","updated_at":"2023-01-31T10:10:43.000Z","dependencies_parsed_at":"2022-08-30T17:10:55.441Z","dependency_job_id":null,"html_url":"https://github.com/boltops-tools/azure_info","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/boltops-tools/azure_info","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boltops-tools%2Fazure_info","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boltops-tools%2Fazure_info/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boltops-tools%2Fazure_info/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boltops-tools%2Fazure_info/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/boltops-tools","download_url":"https://codeload.github.com/boltops-tools/azure_info/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boltops-tools%2Fazure_info/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265881670,"owners_count":23843433,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-16T18:22:40.872Z","updated_at":"2025-07-22T11:03:48.825Z","avatar_url":"https://github.com/boltops-tools.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AzureInfo\n\n[![Gem Version](https://badge.fury.io/rb/azure_info.svg)](https://badge.fury.io/rb/azure_info)\n\n[![BoltOps Badge](https://img.boltops.com/boltops/badges/boltops-badge.png)](https://www.boltops.com)\n\nSimple library to get current Azure info like subscription_id, tenant_id, group, and location.\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'azure_info'\n```\n\nAnd then execute:\n\n    $ bundle install\n\nOr install it yourself as:\n\n    $ gem install azure_info\n\n## Usage\n\n```ruby\nAzureInfo.group\nAzureInfo.location\nAzureInfo.subscription_id\nAzureInfo.tenant_id\n```\n\n## Dependencies\n\nThis tool calls out to the az CLI. So the az CLI is required.\n\n## Precedence\n\nThis library will return values using different sources with this precedence:\n\n1. Environment variables: ARM_GROUP, ARM_LOCATION, ARM_SUBSCRIPTION_ID, ARM_TENANT_ID\n2. az cli: Usually configured in the `~/.azure/config`. Use `az configure --list-defaults` to double check.\n3. Defaults: A default is set for `location=eastus`. The other values must be configured.\n\nThe config file used by the `az` command looks something like this:\n\n~/.azure/config\n\n    [cloud]\n    name = AzureCloud\n\n    [defaults]\n    location = eastus\n\nThis command is also useful:\n\n    az account show\n\n## Setting the Defaults with az cli\n\n    az login --username EMAIL_ADDRESS -t TENANT_ID\n    az account set --subscription SUBSCRIPTION_ID\n    az configure --defaults location=eastus group=RESOURCE_GROUP\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/boltops-tools/azure_info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fboltops-tools%2Fazure_info","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fboltops-tools%2Fazure_info","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fboltops-tools%2Fazure_info/lists"}