Skip to content

nhost/functions

main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Nhost functions in Docker

Features

  • Hot reload of package.json, lock files, and the functions directory
  • Accepts both Javascript and Typesript
  • Create a package.json file if missing
  • Customisable custom package manager (pnpm by default)
  • No need to add the Express dependency anymore

Example

cd example
cp .env.example .env
# Full Nhost
docker-compose up

# Or only functions
docker-compose up functions traefik

Create a new version

Create a GitHub release, with a new semver tag prefixed with v, for instance v0.1.2

Note

I've added a package.json file to make my IDE happy when developing inside server.ts. Just note: The npm packages in package.json is only for development. You need to update the packages in Dockerfile for them to be used in the docker image.