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

adding plan and container settings to function app #54830

Merged
merged 22 commits into from
Apr 8, 2019

Conversation

zikalino
Copy link
Contributor

@zikalino zikalino commented Apr 4, 2019

SUMMARY

These features are necessary to create container based function apps (like through the portal)

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

azure_rm_functionapp

ADDITIONAL INFORMATION

@ansibot
Copy link
Contributor

ansibot commented Apr 4, 2019

@ansibot ansibot added WIP This issue/PR is a work in progress. Nevertheless it was shared for getting input from peers. affects_2.8 This issue/PR affects Ansible v2.8 azure cloud feature This issue/PR relates to a feature request. module This issue/PR relates to a module. needs_triage Needs a first human triage before being processed. owner_pr This PR is made by the module's maintainer. support:community This issue/PR relates to code supported by the Ansible community. labels Apr 4, 2019
@ansibot
Copy link
Contributor

ansibot commented Apr 4, 2019

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

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:405:18: undefined-variable Undefined variable '_normalize_sku'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:407:22: undefined-variable Undefined variable 'SkuDescription'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:407:42: undefined-variable Undefined variable 'get_sku_name'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:409:23: undefined-variable Undefined variable 'AppServicePlan'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:415:34: undefined-variable Undefined variable 'LROPoller'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:420:19: undefined-variable Undefined variable 'appserviceplan_to_dict'

The test ansible-test sanity --test pep8 [explain] failed with 1 error:

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:170:1: E302 expected 2 blank lines, found 1

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

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:0:0: E309 version_added for new option (container_settings) should be '2.8'. Currently StrictVersion ('0.0')
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:0:0: E309 version_added for new option (plan) should be '2.8'. Currently StrictVersion ('0.0')

click here for bot help

@ansibot
Copy link
Contributor

ansibot commented Apr 4, 2019

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

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:410:42: undefined-variable Undefined variable 'get_sku_name'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:418:34: undefined-variable Undefined variable 'LROPoller'

The test ansible-test sanity --test pep8 [explain] failed with 1 error:

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:173:1: E302 expected 2 blank lines, found 1

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

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:0:0: E309 version_added for new option (container_settings) should be '2.8'. Currently StrictVersion ('0.0')
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:0:0: E309 version_added for new option (plan) should be '2.8'. Currently StrictVersion ('0.0')

click here for bot help

@ansibot
Copy link
Contributor

ansibot commented Apr 4, 2019

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

lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:413:42: undefined-variable Undefined variable 'get_sku_name'
lib/ansible/modules/cloud/azure/azure_rm_functionapp.py:421:34: undefined-variable Undefined variable 'LROPoller'

click here for bot help

@zikalino zikalino changed the title [WIP] adding plan and container settings to function app adding plan and container settings to function app Apr 4, 2019
@ansibot ansibot added community_review In order to be merged, this PR must follow the community review workflow. and removed WIP This issue/PR is a work in progress. Nevertheless it was shared for getting input from peers. labels Apr 4, 2019
plan:
description:
- App service plan. Required for creation.
- It can be name of existing app service plan in same resource group as web app.
Copy link
Contributor

Choose a reason for hiding this comment

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

as web app sounds confusing..

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, actually it's not required. if not specified, something will be created anyway by the service.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated the doc

- name: "Create azure function app {{ function_app }}"
azure_rm_functionapp:
resource_group: "{{ resource_group }}"
name: af{{ fixed_resource_prefix }}container
Copy link
Contributor

Choose a reason for hiding this comment

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

can you make it a variable?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@ansibot ansibot removed needs_triage Needs a first human triage before being processed. owner_pr This PR is made by the module's maintainer. labels Apr 4, 2019
@ansibot ansibot added needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. and removed community_review In order to be merged, this PR must follow the community review workflow. labels Apr 4, 2019
@ansibot
Copy link
Contributor

ansibot commented Apr 4, 2019

@zikalino zikalino closed this Apr 4, 2019
@zikalino zikalino reopened this Apr 4, 2019
@yungezz
Copy link
Contributor

yungezz commented Apr 4, 2019

ci failed

@zikalino
Copy link
Contributor Author

zikalino commented Apr 4, 2019

@yungezz I think I have just fixed an issue with azure_rm_appserviceplan. hope now ci will succeed

@zikalino
Copy link
Contributor Author

zikalino commented Apr 4, 2019

noooooooooo..... still something wrong with app service plan :-(

@ansibot ansibot added community_review In order to be merged, this PR must follow the community review workflow. and removed needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels Apr 4, 2019

if isinstance(poller, AzureOperationPoller):
response = self.get_poller_result(poller)
if isinstance(response, LROPoller) or isinstance(response, AzureOperationPoller):
Copy link
Contributor

Choose a reason for hiding this comment

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

let's standardize the get poller operation. how about direct get_poller_result?

@zikalino zikalino merged commit ea609c3 into ansible:devel Apr 8, 2019
@zikalino zikalino deleted the new-options-in-function-app branch April 8, 2019 03:05
@ansible ansible locked and limited conversation to collaborators Jul 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.8 This issue/PR affects Ansible v2.8 azure cloud community_review In order to be merged, this PR must follow the community review workflow. feature This issue/PR relates to a feature request. module This issue/PR relates to a module. support:community This issue/PR relates to code supported by the Ansible community.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants