Site being deployed to path matching base directory, not domain root

I have a repo with a subdirectory www/ that contains the code for the frontend of my app (a single-page and one lambda function), and in my netlify.toml I’m pointing netlify to that subdfolder as it’s base. However when building the site, netlify only deploys it to as opposed to I’ve tried a bunch of changes to the toml file and in the UI but aren’t getting anywhere. Is there something I’m missing?

The only thing that needs a build step is my function (using netlify-lambda), which looks like it is being deployed to the site’s root.

Current rough folder structure:

| |
| |____index.html
| |____Functions
| | |____function.js
| |____package.json

And my netlify.toml:

  base = "www"
  publish = "www"      # I've tried "build", "" and "www/build"

I can fix the issue by having the index.html for the site in the repository root, and then referencing all other files (css, js, images) from inside that folder. But this way even my server code gets deployed to

Ideally I would just like the www/ folder to be published, like the build output from a gatsby site would be, for example.

hey @neefrehman,

Are you generating anything as part of the build step? If not, as in, you have already got the html, you don’t need to set a base directory and can just point the publish directory to where the html files live. Can you try and see if that works?

That worked! :man_facepalming:t4:

I always thought that publish had to be a subdirectory of base! can’t believe I didn’t try that.

1 Like

no problem! glad its working meow :+1::cat: