mirror of
https://github.com/openfaas/faas.git
synced 2025-06-09 00:36:46 +00:00
Publish multi-arch alpine base
This makes functions/alpine:latest into a multi-arch image. Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
This commit is contained in:
parent
27f5c34389
commit
83d3a1ef87
@ -1,6 +1,6 @@
|
|||||||
FROM openfaas/classic-watchdog:0.18.8 as watchdog
|
FROM --platform=${TARGETPLATFORM:-linux/amd64} ghcr.io/openfaas/classic-watchdog:0.1.4 as watchdog
|
||||||
|
|
||||||
FROM alpine:3.11
|
FROM --platform=${TARGETPLATFORM:-linux/amd64} alpine:3.12
|
||||||
|
|
||||||
COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
|
COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
|
||||||
RUN chmod +x /usr/bin/fwatchdog
|
RUN chmod +x /usr/bin/fwatchdog
|
||||||
|
@ -1,15 +0,0 @@
|
|||||||
FROM openfaas/classic-watchdog:0.18.8 as watchdog
|
|
||||||
|
|
||||||
FROM alpine:3.11
|
|
||||||
|
|
||||||
COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
|
|
||||||
RUN chmod +x /usr/bin/fwatchdog
|
|
||||||
|
|
||||||
# Populate example here
|
|
||||||
# ENV fprocess="wc -l"
|
|
||||||
|
|
||||||
RUN addgroup -g 1000 -S app && adduser -u 1000 -S app -G app
|
|
||||||
USER 1000
|
|
||||||
|
|
||||||
HEALTHCHECK --interval=5s CMD [ -e /tmp/.lock ] || exit 1
|
|
||||||
CMD ["fwatchdog"]
|
|
@ -1,15 +0,0 @@
|
|||||||
FROM openfaas/classic-watchdog:0.18.8 as watchdog
|
|
||||||
|
|
||||||
FROM alpine:3.11
|
|
||||||
|
|
||||||
COPY --from=watchdog /fwatchdog /usr/bin/fwatchdog
|
|
||||||
RUN chmod +x /usr/bin/fwatchdog
|
|
||||||
|
|
||||||
# Populate example here
|
|
||||||
# ENV fprocess="wc -l"
|
|
||||||
|
|
||||||
RUN addgroup -g 1000 -S app && adduser -u 1000 -S app -G app
|
|
||||||
USER 1000
|
|
||||||
|
|
||||||
HEALTHCHECK --interval=5s CMD [ -e /tmp/.lock ] || exit 1
|
|
||||||
CMD ["fwatchdog"]
|
|
10
sample-functions/base.yml
Normal file
10
sample-functions/base.yml
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
provider:
|
||||||
|
name: openfaas
|
||||||
|
gateway: http://127.0.0.1:8080 # can be a remote server
|
||||||
|
|
||||||
|
functions:
|
||||||
|
alpine-function:
|
||||||
|
lang: dockerfile
|
||||||
|
handler: ./alpinefunction
|
||||||
|
image: functions/alpine:latest-multiarch
|
||||||
|
platforms: linux/amd64,linux/arm64,linux/arm/7
|
Loading…
x
Reference in New Issue
Block a user