Site name: vigorous-bell-99b0d9
Hey, we recently migrated from Next.js v11.1.3 to v12.1.0 while also upgrading the following:
@netlify/plugin-nextjs: from v3.9.2 to v4.2.7
netlify-cli: from v8.0.1 to v9.8.3
After our project is being build using the command netlify build --offline
it is getting deployed on netlify upon which it is not able to load static contents like css & js:
In the build logs, we’re getting this:
...
(build.command completed in 1m 10.9s)
────────────────────────────────────────────────────────────────
3. @netlify/plugin-nextjs (onBuild event)
────────────────────────────────────────────────────────────────
Patching /home/[REDACTED]/node_modules/next/dist/server/base-server.js
Done
Moving static page files to serve from CDN...
Moved 42 files
Netlify configuration property "redirects" value changed to [
{ from: '/_next/static/*', to: '/static/:splat', status: 200 },
{
from: '/_next/image*',
query: { url: ':url', w: ':width', q: ':quality' },
to: '/_ipx/w_:width,q_:quality/:url',
status: 301
},
{ from: '/_ipx/*', to: '/.netlify/builders/_ipx', status: 200 },
{ from: '/cache/*', to: '/404.html', status: 404, force: true },
{ from: '/server/*', to: '/404.html', status: 404, force: true },
{ from: '/serverless/*', to: '/404.html', status: 404, force: true }
...
so netlify is setting redirect rules as much as I can understand but on trying to load the website it’s still calling _next
as seen in the first screenshot.
Kindly help by letting us know, is there any custom step we need to take care of to either change the static content path in html files or to redirect properly?