-
Couldn't load subscription status.
- Fork 15
Add Cloudflare IP range importer #572
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
Conversation
|
@mrchrisadams I think this PR is ready for review. I'm not sure how it can be tested or verified though. Will take your lead. |
|
hi @fershad ! If the importer works by fetching data, and then importing it, we could check by writing a test to run the importer and see if the provider, has the new IP ranges added. Are you cool with me adding a test along these lines to this PR? |
|
Thanks @mrchrisadams. Yes that kind of test does make sense. Please do add it, it would be a good reference to have for future importers as well. |
894c4f3 to
e7a5cd3
Compare
Old Energy EstimationEco-CI Output:
🌳 CO2 Data: |
Old Energy EstimationEco-CI Output:
🌳 CO2 Data: |
|
Hey @fershad - I've added:
|
Old Energy EstimationEco-CI Output:
🌳 CO2 Data: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi Fish! Thanks for making this! I can confirm this adds the IP ranges listed at the endpoints you listed.
I think this is good to merge in, but we'll likely need to make a change later to actually switch this on as I think it make sense to make sure we have a named technical contact to speak to first before running it on the regular.
| dotenv run -- ./manage.py update_networks_in_db_microsoft | ||
|
|
||
| # TODO: activate once we have found our technical contact to talk to | ||
| # dotenv run -- ./manage.py update_networks_in_db_cloudflare |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is the command we would run on weekly import like we do with AWS, GCP, and Microsoft
|
Eco-CI Output:
🌳 CO2 Data: |
|
Hey @mrchrisadams @fershad FYI, i'm gonna take over this branch and get it over the line! Warning you as am about to force-push a mahooosive rebase :-) |
3be2700 to
327d87c
Compare
|
Deployment checklist:
|
|
(Added the extra env variable plumbing in the github deploy pipeline and ansible template) |
Fixes #569
This PR creates a new Importer for Cloudflare's public IP ranges. It fetches data from two text files which reflect the public IPv4 and IPv6 ranges that Cloudflare maintain.
TXT IPv4 list: https://www.cloudflare.com/ips-v4/#
TXT IPv6 list: https://www.cloudflare.com/ips-v6/#