I am having trouble setting up a deploy for my Remix project that is contained within an NX mono-repo.
the deploy executes successfully, but I get 404s from when visiting the site. If there is something apparent that I am doing incorrectly I would love some correction.
Here is the site: https://glowing-pony-b2662a.netlify.app
Here are my deploy settings:
Base directory: /
Build command: npx nx build market
Publish directory: /packages/market
Here is my toml file:
command = “remix build”
functions = “netlify/functions”
publish = “public”
command = “remix watch”
port = 3000
from = “/*”
to = “/.netlify/functions/server”
status = 200
for = “/build/*”
“Cache-Control” = “public, max-age=31536000, s-maxage=31536000”
Here is a link to the repo
OK I figured it out.
After going through the remix deploy to netlify video by good ol Kent → Deploy Remix to Netlify Serverless Functions in less than 3 minutes - YouTube
- changed my build settings to:
Build command:remix build
Publish directory: /packages/market/public
Generated a public access token
“dev”: “cross-env NODE_ENV=development netlify dev”,
“start”: “cross-env NODE_ENV=production netlify dev”,
ran netlify init & netlify link
ensured deps were listed in /packages/market/package.json as well ass /package.json
added a /packages/market/server.js
7 and updated the /packages/market/remix.config.js
Hey there, @th-m
Thanks so much for coming back and sharing your solution here. This will be beneficial for future Forums members who encounter something similar, so we appreciate it.