Skip to content

Commit 495ccba

Browse files
author
Hanzhang Zeng (Roger)
committed
Added docker file to build custom worker
1 parent 634cb99 commit 495ccba

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

CustomWorker.dockerfile

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
FROM mcr.microsoft.com/azure-functions/python:3.0-python3.6
2+
3+
RUN rm -rf /azure-functions-host/workers/python/3.6/LINUX/X64/azure_functions_worker
4+
5+
COPY azure_functions_worker /azure-functions-host/workers/python/3.6/LINUX/X64/azure_functions_worker
6+
7+
ENV AzureWebJobsScriptRoot=/home/site/wwwroot \
8+
AzureFunctionsJobHost__Logging__Console__IsEnabled=true \
9+
FUNCTIONS_WORKER_PROCESS_COUNT=1 \
10+
PYTHON_THREADPOOL_THREAD_COUNT=1 \
11+
FUNCTIONS_WORKER_RUNTIME_VERSION=3.6
12+
13+
COPY requirements.txt /
14+
RUN pip install --upgrade pip
15+
RUN pip install -r /requirements.txt
16+
17+
COPY . /home/site/wwwroot
18+
19+
CMD [ "/azure-functions-host/Microsoft.Azure.WebJobs.Script.WebHost" ]

0 commit comments

Comments
 (0)