File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11FROM ghcr.io/openfaas/of-watchdog:0.9.3 as watchdog
2- FROM python:2.7-alpine as builder
2+ FROM python:2.7-alpine as build
33
44COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
55RUN chmod +x /usr/bin/fwatchdog
@@ -36,7 +36,7 @@ USER root
3636COPY --chown=app:app function function
3737USER app
3838
39- FROM builder as final
39+ FROM build as ship
4040
4141ENV fprocess="python index.py"
4242ENV cgi_headers="true"
Original file line number Diff line number Diff line change 11FROM --platform=${TARGETPLATFORM:-linux/amd64} ghcr.io/openfaas/of-watchdog:0.9.8 as watchdog
2- FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-slim-buster as builder
2+ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-slim-buster as build
33
44COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
55RUN chmod +x /usr/bin/fwatchdog
@@ -41,13 +41,13 @@ USER root
4141
4242COPY --chown=app:app function/ .
4343
44- FROM builder as tester
44+ FROM build as test
4545ARG TEST_COMMAND=tox
4646ARG TEST_ENABLED=true
4747RUN [ "$TEST_ENABLED" = "false" ] && echo "skipping tests" || eval "$TEST_COMMAND"
4848
4949
50- FROM builder as final
50+ FROM build as ship
5151WORKDIR /home/app/
5252
5353# configure WSGI server and healthcheck
Original file line number Diff line number Diff line change 11FROM --platform=${TARGETPLATFORM:-linux/amd64} ghcr.io/openfaas/of-watchdog:0.9.8 as watchdog
2- FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-alpine as builder
2+ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-alpine as build
33
44COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
55RUN chmod +x /usr/bin/fwatchdog
@@ -40,12 +40,12 @@ USER root
4040COPY --chown=app:app function/ .
4141
4242
43- FROM builder as tester
43+ FROM build as test
4444ARG TEST_COMMAND=tox
4545ARG TEST_ENABLED=true
4646RUN [ "$TEST_ENABLED" = "false" ] && echo "skipping tests" || eval "$TEST_COMMAND"
4747
48- FROM builder as final
48+ FROM build as ship
4949WORKDIR /home/app/
5050
5151# configure WSGI server and healthcheck
Original file line number Diff line number Diff line change 11FROM --platform=${TARGETPLATFORM:-linux/amd64} ghcr.io/openfaas/of-watchdog:0.9.8 as watchdog
2- FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-slim-buster as builder
2+ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-slim-buster as build
33
44COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
55RUN chmod +x /usr/bin/fwatchdog
@@ -36,14 +36,14 @@ RUN pip install --no-cache-dir --user -r requirements.txt
3636USER root
3737COPY --chown=app:app function/ .
3838
39- FROM builder as tester
39+ FROM build as test
4040
4141ARG TEST_COMMAND=tox
4242ARG TEST_ENABLED=true
4343RUN [ "$TEST_ENABLED" = "false" ] && echo "skipping tests" || eval "$TEST_COMMAND"
4444
4545
46- FROM builder as final
46+ FROM build as ship
4747WORKDIR /home/app/
4848
4949USER app
Original file line number Diff line number Diff line change 11FROM --platform=${TARGETPLATFORM:-linux/amd64} ghcr.io/openfaas/of-watchdog:0.9.8 as watchdog
2- FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-alpine as builder
2+ FROM --platform=${TARGETPLATFORM:-linux/amd64} python:3.7-alpine as build
33
44COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
55RUN chmod +x /usr/bin/fwatchdog
@@ -37,12 +37,12 @@ RUN pip install --no-cache-dir --user -r requirements.txt
3737USER root
3838COPY --chown=app:app function/ .
3939
40- FROM builder as tester
40+ FROM build as test
4141ARG TEST_COMMAND=tox
4242ARG TEST_ENABLED=true
4343RUN [ "$TEST_ENABLED" = "false" ] && echo "skipping tests" || eval "$TEST_COMMAND"
4444
45- FROM builder as final
45+ FROM build as ship
4646WORKDIR /home/app/
4747
4848# configure WSGI server and healthcheck
You can’t perform that action at this time.
0 commit comments