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

azure_rm_networkinterface: Feature/dns servers #43588

Merged
merged 6 commits into from
Aug 28, 2018

Conversation

spmp
Copy link
Contributor

@spmp spmp commented Aug 2, 2018

SUMMARY

Add dns_servers option to azure_rm_networkinterface

ISSUE TYPE
  • New Module Pull Request
COMPONENT NAME

azure_rm_networkinterface

ANSIBLE VERSION
2.7

@ansibot
Copy link
Contributor

ansibot commented Aug 2, 2018

@ansibot
Copy link
Contributor

ansibot commented Aug 2, 2018

Hi @spmp,

Thank you for the pullrequest, just so you are aware we have a dedicated Working Group for azure.
You can find other people interested in this in #ansible-azure on Freenode IRC
For more information about communities, meetings and agendas see https://github.com/ansible/community

click here for bot help

@ansibot ansibot added affects_2.7 This issue/PR affects Ansible v2.7 azure cloud committer_review In order to be merged, this PR must follow the certified review workflow. module This issue/PR relates to a module. needs_triage Needs a first human triage before being processed. new_plugin This PR includes a new plugin. support:certified This issue/PR relates to certified code. test This PR relates to tests. labels Aug 2, 2018
@ansibot
Copy link
Contributor

ansibot commented Aug 2, 2018

The test ansible-test sanity --test validate-modules [explain] failed with 2 errors:

lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:534:0: E403 Type comparison using type() found. Use isinstance() instead
lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:535:0: E403 Type comparison using type() found. Use isinstance() instead

click here for bot help

@ansibot ansibot added needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. and removed committer_review In order to be merged, this PR must follow the certified review workflow. labels Aug 2, 2018
@jborean93 jborean93 removed the needs_triage Needs a first human triage before being processed. label Aug 2, 2018
@gundalow gundalow changed the title Feature/dns servers azure_rm_networkinterface: Feature/dns servers Aug 2, 2018
@ansibot
Copy link
Contributor

ansibot commented Aug 3, 2018

The test ansible-test sanity --test validate-modules [explain] failed with 2 errors:

lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:534:0: E403 Type comparison using type() found. Use isinstance() instead
lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:535:0: E403 Type comparison using type() found. Use isinstance() instead

click here for bot help

@ansibot ansibot added the ci_verified Changes made in this PR are causing tests to fail. label Aug 3, 2018
@ansibot ansibot removed the ci_verified Changes made in this PR are causing tests to fail. label Aug 3, 2018
@ansibot
Copy link
Contributor

ansibot commented Aug 3, 2018

The test ansible-test sanity --test pylint [explain] failed with 2 errors:

lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:534:63: undefined-variable Undefined variable 'istype'
lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:535:62: undefined-variable Undefined variable 'istype'

The test ansible-test sanity --test pep8 [explain] failed with 2 errors:

lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:534:64: E721 do not compare types, use 'isinstance()'
lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:535:63: E721 do not compare types, use 'isinstance()'

The test ansible-test sanity --test validate-modules [explain] failed with 2 errors:

lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:534:0: E403 Type comparison using type() found. Use isinstance() instead
lib/ansible/modules/cloud/azure/azure_rm_networkinterface.py:535:0: E403 Type comparison using type() found. Use isinstance() instead

click here for bot help

@ansibot ansibot added committer_review In order to be merged, this PR must follow the certified review workflow. and removed needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels Aug 5, 2018
@@ -1,29 +1,34 @@
- name: Prepare random number
set_fact:
rpfx: "{{ resource_group | hash('md5') | truncate(7, True, '') }}{{ 1000 | random }}"
auth_source: auto
Copy link
Contributor

Choose a reason for hiding this comment

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

no need to add auth_source

resource_group: "{{ resource_group_secondary }}"
name: "tn{{ rpfx }}"
address_prefixes: "10.10.0.0/16"
resource_group: "{{ resource_group_secondary }}"
Copy link
Contributor

Choose a reason for hiding this comment

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

Hi @spmp As we talked this morning, please make the test with 4 spaces

@@ -512,6 +529,16 @@ def exec_module(self, **kwargs):
results.get('enable_accelerated_networking')))
changed = True

# We need to ensure that dns_servers are list like
dns_servers_res = results.get('dns_settings').get('dns_servers')
Copy link
Contributor

Choose a reason for hiding this comment

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

Null check for dns_settings here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

dns_settings should never be null as it comes from network_client.network_interfaces.get()
Certainly can test, but we could miss breaking API changes from Azure SDK if we do this...

Just for fun: The DNS settings does not conform to published API from a setting perspective BTW. I had an interesting conversation with the Azure Architect (or an architect) about this.... turns out you cannot set anything except dns_servers, hence only this option. Well, you can set them, they are simply ignored.

@ansibot ansibot added needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. and removed committer_review In order to be merged, this PR must follow the certified review workflow. labels Aug 9, 2018
@ansibot ansibot removed the needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. label Aug 10, 2018
@ansibot ansibot added the needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. label Aug 13, 2018
@Fred-sun
Copy link
Contributor

@spmp Thanks for your contribution, Could you please resolve conflicting files?

@spmp
Copy link
Contributor Author

spmp commented Aug 14, 2018

@Fred-sun rebased

@ansibot ansibot removed the needs_rebase https://docs.ansible.com/ansible/devel/dev_guide/developing_rebasing.html label Aug 14, 2018
@ansibot ansibot added committer_review In order to be merged, this PR must follow the certified review workflow. and removed needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels Aug 15, 2018
@Fred-sun
Copy link
Contributor

@spmp Thanks for your contribution, Does this PR ready for review or not?

@spmp
Copy link
Contributor Author

spmp commented Aug 15, 2018

@Fred-sun yes this is ready for review

@Fred-sun
Copy link
Contributor

@spmp Thanks for your update, I will push review. Thanks!

@Fred-sun
Copy link
Contributor

@yuwzho Could you help approve those change? Thanks!

@yuwzho
Copy link
Contributor

yuwzho commented Aug 16, 2018

@jborean93 for a further review

@Fred-sun
Copy link
Contributor

@jborean93 Could you help take a look this PR? Thanks!

2 similar comments
@Fred-sun
Copy link
Contributor

@jborean93 Could you help take a look this PR? Thanks!

@Fred-sun
Copy link
Contributor

@jborean93 Could you help take a look this PR? Thanks!

@ansibot ansibot added the stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. label Aug 24, 2018
@Fred-sun
Copy link
Contributor

@jborean93 Could you help take a look this PR? we need push this PR to next step . Thanks!

@nitzmahone nitzmahone merged commit 56ea56f into ansible:devel Aug 28, 2018
@spmp spmp deleted the feature/dns_servers branch August 29, 2018 20:33
@spmp
Copy link
Contributor Author

spmp commented Aug 29, 2018

Cheers @nitzmahone

@ansible ansible locked and limited conversation to collaborators Jul 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.7 This issue/PR affects Ansible v2.7 azure cloud committer_review In order to be merged, this PR must follow the certified review workflow. module This issue/PR relates to a module. new_plugin This PR includes a new plugin. stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. support:certified This issue/PR relates to certified code. test This PR relates to tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants