mirror of
https://github.com/openfaas/faas.git
synced 2025-06-20 22:06:34 +00:00
Add NodeBase function concept
This commit is contained in:
18
sample-functions/NodeBaseFunction/Dockerfile
Normal file
18
sample-functions/NodeBaseFunction/Dockerfile
Normal file
@ -0,0 +1,18 @@
|
||||
FROM node:6.9.1-alpine
|
||||
|
||||
ADD https://github.com/alexellis/faas/releases/download/0.5.1-alpha/fwatchdog /usr/bin
|
||||
RUN chmod +x /usr/bin/fwatchdog
|
||||
|
||||
WORKDIR /root/
|
||||
|
||||
COPY package.json .
|
||||
|
||||
# Provides a boot-strap into your function, just add handler.js to derived image
|
||||
RUN npm i
|
||||
COPY faas_index.js .
|
||||
|
||||
ENV fprocess="node faas_index.js"
|
||||
|
||||
HEALTHCHECK --interval=5s CMD [ -e /tmp/.lock ] || exit 1
|
||||
|
||||
CMD ["fwatchdog"]
|
Reference in New Issue
Block a user