MCPcopy Create free account
hub / github.com/adobe/Marinus / update_azure_cidrs

Function update_azure_cidrs

python3_cron_scripts/send_remote_server.py:112–124  ·  view source on GitHub ↗

Copy the list of Azure CIDRs to the remote database

(logger, mongo_connector, rm_connector)

Source from the content-addressed store, hash-verified

110
111
112def update_azure_cidrs(logger, mongo_connector, rm_connector):
113 """
114 Copy the list of Azure CIDRs to the remote database
115 """
116 logger.info("Starting Azure IPs..")
117 azure_ips_collection = mongo_connector.get_azure_ips_connection()
118 remote_azure_ips_collection = rm_connector.get_azure_ips_connection()
119
120 azure_ips = azure_ips_collection.find({}, {"_id": 0})
121
122 remote_azure_ips_collection.delete_many({})
123 for ip_addr in azure_ips:
124 remote_azure_ips_collection.insert_one(ip_addr)
125
126
127def update_akamai_cidrs(logger, mongo_connector, rm_connector):

Callers 1

mainFunction · 0.85

Calls 1

Tested by

no test coverage detected