From repo root:
docker build -t bfast-function .docker run --rm -p 3000:3000 \
-e PORT=3000 \
-v "$(pwd)/functions:/faas/functions" \
bfast-functionUse this when your image/container should execute local function files.
docker run --rm -p 3000:3000 \
-e PORT=3000 \
-e MODE=git \
-e GIT_CLONE_URL=https://github.com/acme/functions.git \
-e GIT_USERNAME=acme-bot \
-e GIT_TOKEN=*** \
bfast-functiondocker run --rm -p 3000:3000 \
-e PORT=3000 \
-e MODE=npm \
-e NPM_TAR=acme-functions \
bfast-functiondocker run --rm -p 3000:3000 \
-e PORT=3000 \
-e MODE=url \
-e URL_TAR=https://example.com/functions.tgz \
bfast-functionContainer entrypoint runs:
npm run startwhich executes src/start.mjs.
- Do not place tokens in image layers.
- Prefer runtime-injected secrets (swarm/k8s secrets, vault, env injection at deploy time).
- Pin image versions/tags instead of relying on mutable
latestin production.