File tree Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Original file line number Diff line number Diff line change 1
- FROM fnproject/python:3.6-dev
1
+ FROM fnproject/python:3.6-dev as build-stage
2
2
WORKDIR /function
3
3
ADD requirements.txt /function/
4
- RUN pip3 install --no-cache --no-cache-dir --upgrade pip && \
5
- pip3 install --target /python/ --no-cache --no-cache-dir -r requirements.txt && \
6
- rm -fr ~/.cache/pip /tmp* requirements.txt func.yaml Dockerfile .venv && \
7
- chmod -R o+r /function
4
+
5
+ RUN pip3 install --target /python/ --no-cache --no-cache-dir -r requirements.txt &&\
6
+ rm -fr ~/.cache/pip /tmp* requirements.txt func.yaml Dockerfile .venv &&\
7
+ chmod -R o+r /python
8
8
ADD . /function/
9
9
RUN rm -fr /function/.pip_cache
10
-
11
10
FROM fnproject/python:3.6
12
11
RUN microdnf install oracle-epel-release-el8 &&\
13
12
microdnf install ImageMagick &&\
14
13
microdnf remove oracle-epel-release-el8 &&\
15
14
microdnf clean all
16
15
WORKDIR /function
17
- COPY --from=build-stage /function /function
18
16
COPY --from=build-stage /python /python
19
- ENV PYTHONPATH=/python:/function
17
+ COPY --from=build-stage /function /function
18
+ RUN chmod -R o+r /function
19
+ ENV PYTHONPATH=/function:/python
20
20
ENTRYPOINT ["/python/bin/fdk" , "/function/func.py" , "handler" ]
21
-
You can’t perform that action at this time.
0 commit comments