user29140482
user29140482

Reputation: 3

Getting error running webjobs in Azure Linux app

I'm running a simple Python webjob in an Azure Linux webapp.

I am getting this error

Run script 'webjob.py' with script host - 'PythonScriptHost'
f24041: SYS INFO] Status changed to Running
 f24041: ERR ] An error occurred trying to start process 'python.exe' with working directory '/tmp/jobs/continuous/test/qsinu4ck.4pl'. No such file or directory f24041: SYS ERR ] System.AggregateException: One or more errors occurred. (An error occurred trying to start process 'python.exe' with working directory '/tmp/jobs/continuous/test/qsinu4ck.4pl'. No such file or directory)
 ---> System.ComponentModel.Win32Exception (2): An error occurred trying to start process 'python.exe' with working directory '/tmp/jobs/continuous/test/qsinu4ck.4pl'. No such file or directory 

What can I try next?

Upvotes: 0

Views: 82

Answers (1)

Sirra Sneha
Sirra Sneha

Reputation: 1197

I created a sample python WebJob script and successfully uploaded it to Azure WebJobs without any issues.

  • The issue is related to PythonScriptHost because the linux App service's webjob is still in preview.

  • You need to create the .sh file along with your python file.

My webjob .py:

print("hello")

script .sh:

python3  webjob.py

I've zipped these files and uploaded it to Azure webjobs.

enter image description here

Here's the output logs:

enter image description here

Upvotes: 0

Related Questions