Azure / azure-cli

Azure Command-Line Interface
MIT License
4.01k stars 2.99k forks source link

Not able to deploy app by zip #21495

Closed keyss-manoj closed 2 years ago

keyss-manoj commented 2 years ago

This is autogenerated. Please review and update as needed.

Describe the bug

Command Name az functionapp deployment source config-zip

Errors:

The command failed with an unexpected error. Here is the traceback:
[Errno 2] No such file or directory: 'D:\\collection\\public\\projects\\nrf-asset-tracker\\azure\\functionapp.zip'
Traceback (most recent call last):
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\knack/cli.py", line 231, in invoke
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 658, in execute
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 721, in _run_jobs_serially
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 692, in _run_job
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/__init__.py", line 328, in __call__
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/core/commands/command_operation.py", line 121, in handler
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/appservice/custom.py", line 512, in enable_zip_deploy_functionapp
  File "D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/appservice/custom.py", line 542, in enable_zip_deploy
FileNotFoundError: [Errno 2] No such file or directory: 'D:\\collection\\public\\projects\\nrf-asset-tracker\\azure\\functionapp.zip'

To Reproduce:

Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

Expected Behavior

Environment Summary

Windows-10-10.0.22000-SP0
Python 3.8.9
Installer: MSI

azure-cli 2.34.0

Extensions:
azure-iot 0.13.0

Dependencies:
msal 1.16.0
azure-mgmt-resource 20.0.0

Additional Context

yonzhan commented 2 years ago

route to CXP team

SubhashVasarapu-MSFT commented 2 years ago

@keyss-manoj , the error indicates that the file is missing from the specified location. Do retry with the correct zip location.

keyss-manoj commented 2 years ago

@SubhashVasarapu-MSFT I am following this link https://nordicsemiconductor.github.io/asset-tracker-cloud-docs/v1.8.x/docs/azure/GettingStarted/Deploy.html, on step 18, I run this command node dist/pack/package-function-app.js functionapp.zip to generate zip file but when I tried to run this command az functionapp deployment source config-zip -g nrfassettracker -n nrfassettrackerapi --src functionapp.zip

panchagnula commented 2 years ago

@keyss-manoj the error "D:\collection\public\projects\nrf-asset-tracker\azure\functionapp.zip" indicates the command is not able to find or each this location. Make sure to use the full location in --src or copy the zip to this location where the command is running from. Thanks!

panchagnula commented 2 years ago

Closing due to lack of response. Please re-open if this still repros on the latest version