Share via

unabl to deploy azure function

cloudwithdeb 41 Reputation points
2022-02-19T12:17:14.57+00:00

I have an azure function running locally on ubuntu 20.04 using python SDK. I created function app consumption tier on azure inother to deploy this function. When I try to deploy this function, I get the follwoing output but the function doesn't get deployed. Please can someone assist me thanks.

11:58:35 AM azSMSLandingPageFuncAppDev: Starting deployment...
11:58:59 AM azSMSLandingPageFuncAppDev: Creating zip package...
11:58:59 AM azSMSLandingPageFuncAppDev: Zip package size: 2.08 kB
11:59:00 AM azSMSLandingPageFuncAppDev: Fetching changes.
11:59:03 AM azSMSLandingPageFuncAppDev: Updating submodules.
11:59:04 AM azSMSLandingPageFuncAppDev: Preparing deployment for commit id '413bfc33f7'.
11:59:04 AM azSMSLandingPageFuncAppDev: Repository path is /tmp/zipdeploy/extracted
11:59:04 AM azSMSLandingPageFuncAppDev: Running post deployment command(s)...
11:59:04 AM azSMSLandingPageFuncAppDev: Triggering recycle (preview mode disabled).
11:59:04 AM azSMSLandingPageFuncAppDev: Linux Consumption plan has a 1.5 GB memory limit on a remote build container.
11:59:04 AM azSMSLandingPageFuncAppDev: To check our service limit, please visit https://learn.microsoft.com/en-us/azure/azure-functions/functions-scale#service-limits
11:59:04 AM azSMSLandingPageFuncAppDev: Creating placeholder blob for linux consumption function app...
11:59:04 AM azSMSLandingPageFuncAppDev: SCM_RUN_FROM_PACKAGE placeholder blob scm-latest-azSMSLandingPageFuncAppDev.zip located
11:59:04 AM azSMSLandingPageFuncAppDev: Writing the artifacts to a squashfs file
11:59:04 AM azSMSLandingPageFuncAppDev: Parallel mksquashfs: Using 1 processor
11:59:04 AM azSMSLandingPageFuncAppDev: Creating 4.0 filesystem on /home/site/artifacts/functionappartifact.squashfs, block size 131072.
11:59:04 AM azSMSLandingPageFuncAppDev: Exportable Squashfs 4.0 filesystem, gzip compressed, data block size 131072
11:59:04 AM azSMSLandingPageFuncAppDev: compressed data, compressed metadata, compressed fragments, compressed xattrs
11:59:04 AM azSMSLandingPageFuncAppDev: duplicates are removed
11:59:04 AM azSMSLandingPageFuncAppDev: Filesystem size 0.15 Kbytes (0.00 Mbytes)
11:59:04 AM azSMSLandingPageFuncAppDev: 99.37% of uncompressed filesystem size (0.15 Kbytes)
11:59:04 AM azSMSLandingPageFuncAppDev: Inode table size 29 bytes (0.03 Kbytes)
11:59:04 AM azSMSLandingPageFuncAppDev: 85.29% of uncompressed inode table size (34 bytes)
11:59:04 AM azSMSLandingPageFuncAppDev: Directory table size 0 bytes (0.00 Kbytes)
11:59:04 AM azSMSLandingPageFuncAppDev: -nan% of uncompressed directory table size (0 bytes)
11:59:04 AM azSMSLandingPageFuncAppDev: Number of duplicate files found 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of inodes 1
11:59:04 AM azSMSLandingPageFuncAppDev: Number of files 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of fragments 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of symbolic links 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of device nodes 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of fifo nodes 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of socket nodes 0
11:59:04 AM azSMSLandingPageFuncAppDev: Number of directories 1
11:59:04 AM azSMSLandingPageFuncAppDev: Number of ids (unique uids + gids) 1
11:59:04 AM azSMSLandingPageFuncAppDev: Number of uids 1
11:59:04 AM azSMSLandingPageFuncAppDev: root (0)
11:59:04 AM azSMSLandingPageFuncAppDev: Number of gids 1
11:59:04 AM azSMSLandingPageFuncAppDev: root (0)
11:59:04 AM azSMSLandingPageFuncAppDev: Uploading built content /home/site/artifacts/functionappartifact.squashfs for linux consumption function app...
11:59:05 AM azSMSLandingPageFuncAppDev: Resetting all workers for azsmslandingpagefuncappdev.azurewebsites.net
11:59:05 AM azSMSLandingPageFuncAppDev: Deployment successful.
11:59:31 AM azSMSLandingPageFuncAppDev: Syncing triggers...
11:59:38 AM azSMSLandingPageFuncAppDev: Querying triggers...
11:59:50 AM azSMSLandingPageFuncAppDev: No HTTP triggers found.

Azure Functions
Azure Functions

An Azure service that provides an event-driven serverless compute platform.


Answer accepted by question author

MughundhanRaveendran-MSFT 12,511 Reputation points
2022-02-24T10:17:13.677+00:00

@cloudwithdeb ,

Thanks for reaching out to Q&A.

It appears that the package uri is not proper or incorrect. Since you had provided the appname, I had a look into the deployment logs available at my end (MS internal) and found that the deployments resulted with the status code 404.

I would suggest you to upload the zip file to a blob storage container, get the SAS url or just the public url of the zip package and pass it as a value to the below app setting. Please note that, you need to add this app settings if its not present at the moment.

App setting: WEBSITE_RUN_FROM_PACKAGE

Value: zip package uri

Please refer to this article: https://learn.microsoft.com/en-us/azure/app-service/deploy-run-package#run-from-external-url-instead

I hope this helps!

Please 'Accept as answer' and ‘Upvote’ if it helped so that it can help others in the community looking for help on similar topics.

Was this answer helpful?

0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.