question

EspenJohannessen-5003 avatar image
0 Votes"
EspenJohannessen-5003 asked ·

How to best YML/Task deploy Web Job to \home\site\jobs instead of home\site\wwwroot

We have a Web Job I need to deploy and run under \home\site\jobs in an App Service. We allready deploy the website itself via .yml-files with tasks (AzureRmWebAppDeployment@4).

The reason that I cannot deploy under home\site\wwwroot is that the Web Job needs to write to files which is not allowed since we use RUN_FROM_PACKAGE=1 on the website itself.

I have read several approaches to this (FTP-tasks and complicated powershell-scripts), but I imagine there is some more elegant way to accomplish this?

The task is simple: Take a .zip-file that is already present in the ArtifactStagingDirectory and unzip it under the folder \home\site\jobs\triggered\<jobname> (and start the job if it does not autostart with a jobs.settings file).


azure-webapps-webjobs
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

EspenJohannessen-7963 avatar image
0 Votes"
EspenJohannessen-7963 answered ·

Ended up using home\site\wwwroot as deploy location, keeping the write-protection and rewriting the application to use Azure Blob storage to solve my need to write to files.

·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.