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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Microsoft Azure Compute Resources #554

Merged
merged 54 commits into from
Mar 10, 2021

Conversation

mpurusottamc
Copy link
Contributor

This PR is to add initial support of Azure. This intel module currently support only a limited set of Compute related resources like VirtualMachines, DataDisks, Disks and Snapshots. In future, we will extend this furture to include other compute related resources

Currently, the hierarchy is AzureTenant -> AzureSubscription -> VirtualMachine

Also, once reviewed, we want to open pull requests for other resources like Azure Storage, SQL and CosmosDB.

mpurusottamc and others added 30 commits December 5, 2020 07:47
# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.
# Conflicts:
#	cartography/intel/azure/__init__.py
#	cartography/intel/azure/compute.py
#	cartography/intel/azure/tenant.py
# Conflicts:
#	cartography/cli.py
#	cartography/config.py
Copy link
Contributor

@achantavy achantavy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super exciting to see another cloud added to cartography :-)

Mostly left comments on exception handling but this is looking great so far.

cartography/intel/azure/compute.py Outdated Show resolved Hide resolved
cartography/intel/azure/compute.py Outdated Show resolved Hide resolved
cartography/intel/azure/compute.py Outdated Show resolved Hide resolved
cartography/intel/azure/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/subscription.py Outdated Show resolved Hide resolved
cartography/intel/azure/subscription.py Outdated Show resolved Hide resolved
@mpurusottamc
Copy link
Contributor Author

@achantavy Thanks for reviewing the pull request. All the feedback has been incorporated.

Copy link
Contributor

@achantavy achantavy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nearly there! Some nitpicky doc stuff

cartography/intel/azure/util/credentials.py Show resolved Hide resolved
cartography/intel/azure/util/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/util/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/util/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/util/credentials.py Outdated Show resolved Hide resolved
cartography/intel/azure/__init__.py Outdated Show resolved Hide resolved
cartography/intel/azure/tenant.py Outdated Show resolved Hide resolved
cartography/cli.py Outdated Show resolved Hide resolved
cartography/cli.py Outdated Show resolved Hide resolved
@mpurusottamc
Copy link
Contributor Author

@achantavy Updated code to resolve all the comments above.

achantavy
achantavy previously approved these changes Mar 10, 2021
Copy link
Contributor

@achantavy achantavy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One final minor comment from me. Ship it :)

setup.py Outdated
"python-digitalocean>=1.16.0",
"PyJWT==1.7.1",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this need to be pinned? Can it be >=1.7.1 instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

azure-cli-core has pinned it to 1.7.1. I tried with >=1.7.1 and it works. But, there's an error notice in logs while installing the dependencies. I did not want to be the cause of someone's CI/CD pipeline failure :)

What do you recommend? @achantavy

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pin it to 1.7.1 and add a comment on why -- that should be good enough

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@achantavy I have added a comment and pinned the version. Please review and merge.

Copy link
Contributor

@achantavy achantavy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🥂

@achantavy achantavy changed the title Support for Azure Intel module with Compute Resources Add support for Microsoft Azure Compute Resources Mar 10, 2021
@achantavy achantavy merged commit f184ed5 into lyft:master Mar 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants