microsoft / vscode-azurefunctions

Azure Functions extension for VS Code
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions
MIT License
291 stars 134 forks source link

Deployment from Pipelines to Linux container doesn't copy files #1679

Closed M0ns1gn0r closed 5 years ago

M0ns1gn0r commented 5 years ago

Repro:

  1. Create a .NET Function App on Linux Consumption plan.
  2. Setup deployment in Azure DevOps Pipelines using AzureFunctionApp@1 task.
  3. Run the pipeline.
  4. Observe successful deployment in the portal without any error or warning messages (even in the verbose mode).

Expected: the function app is deployed, the functions are displayed on the portal and can be executed.

Actual: the app is not deployed, no functions on the portal, the target deployment location (watched via ftp) is empty.

(!) However, the deployment works if deployed from VS Code or if the Windows Consumption plan is selected.


Additional log:

2019-11-13T14:54:20.003Z - Updating submodules.
2019-11-13T14:54:20.013Z - Preparing deployment for commit id 'b7d91f35e4'.
2019-11-13T14:54:20.032Z - Skipping build. Project type: Run-From-Zip
2019-11-13T14:54:20.036Z - Skipping post build. Project type: Run-From-Zip
2019-11-13T14:54:20.049Z - Writing the artifacts to a squashfs file
2019-11-13T14:54:20.143Z - Parallel mksquashfs: Using 1 processor
2019-11-13T14:54:20.146Z - Creating 4.0 filesystem on /home/site/deployments/functionappartifact.squashfs, block size 131072.
2019-11-13T14:54:20.155Z - Exportable Squashfs 4.0 filesystem, gzip compressed, data block size 131072
2019-11-13T14:54:20.158Z -  compressed data, compressed metadata, compressed fragments, compressed xattrs
2019-11-13T14:54:20.160Z -  duplicates are removed
2019-11-13T14:54:20.167Z - Filesystem size 0.15 Kbytes (0.00 Mbytes)
2019-11-13T14:54:20.170Z -  99.37% of uncompressed filesystem size (0.15 Kbytes)
2019-11-13T14:54:20.177Z - Inode table size 29 bytes (0.03 Kbytes)
2019-11-13T14:54:20.181Z -  85.29% of uncompressed inode table size (34 bytes)
2019-11-13T14:54:20.184Z - Directory table size 0 bytes (0.00 Kbytes)
2019-11-13T14:54:20.187Z -  -nan% of uncompressed directory table size (0 bytes)
2019-11-13T14:54:20.190Z - Number of duplicate files found 0
2019-11-13T14:54:20.192Z - Number of inodes 1
2019-11-13T14:54:20.195Z - Number of files 0
2019-11-13T14:54:20.198Z - Number of fragments 0
2019-11-13T14:54:20.202Z - Number of symbolic links  0
2019-11-13T14:54:20.205Z - Number of device nodes 0
2019-11-13T14:54:20.209Z - Number of fifo nodes 0
2019-11-13T14:54:20.212Z - Number of socket nodes 0
2019-11-13T14:54:20.214Z - Number of directories 1
2019-11-13T14:54:20.217Z - Number of ids (unique uids + gids) 1
2019-11-13T14:54:20.220Z - Number of uids 1
2019-11-13T14:54:20.225Z -  root (0)
2019-11-13T14:54:20.228Z - Number of gids 1
2019-11-13T14:54:20.230Z -  root (0)
2019-11-13T14:54:20.249Z - Uploading built content /home/site/deployments/functionappartifact.squashfs -> <redacted>
2019-11-13T14:54:20.947Z - Resetting all workers for <redacted>.azurewebsites.net
2019-11-13T14:54:21.063Z - Updating /home/data/SitePackages/packagename.txt with deployment 20191113145419.zip
2019-11-13T14:54:21.079Z - Deployment successful.
2019-11-13T14:54:21.120Z - App container will begin restart within 10 seconds.

I don't known what is going on there ^. But suspicious are the sizes and the number of files. My actual artifact ZIP is 7MB.

ejizba commented 5 years ago

@M0ns1gn0r if I read that correctly, this does work in VS Code, but not Azure Dev Ops? I don't work on the Azure Dev Ops task so I can't really help there. Does this look like the right task?: https://github.com/microsoft/azure-pipelines-tasks/tree/master/Tasks/AzureFunctionAppV1

If so, I would recommend filing an issue on that repo.