Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

261
Views
Netlify-lambda serve redirects from netlify.toml

I have a working netlify-lambda setup. I run netlify-lambda locally and not in the cloud. Upon running

netlify-lambda serve ./functions

the functions I have defined in the /functions folder are served on localhost:9000

I also have my netlify.toml file in my project root, looking like this:

[build]
  functions = "netlify-lambda"
  publish = "build/"
  command = "npm run build"

[[redirects]]
  from = "/test"
  to = "https://google.com"
  status = 200
  force = true

When I remove the [build] part, then the command "netlify-lambda serve" will result in an error. So I conclude that this file is being used. On the other hand the [[redirects]] instruction does nothing at all.

Requests to

localhost:9000/test

or

localhost:9000/.netlify/functions/test

result in an error like

Function invocation failed: Error: Cannot find module '/home/********/netlify-lambda/test'

What am I missing here?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

As described here: https://answers.netlify.com/t/redirects-not-going-to-index-html/20289

Netlify-lambda will only host your functions and nothing else. You’ll need at least the netlify-cli

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!