5 ms·
Multiple domains and languages on the same Next.js site
- dawnerd 6y agoI really wish next would just support multiple domains out of the box. I have two sites that share 99% of the same code but just need slightly different styles and endpoints.
- giovannibonetti 6y agoThat can be dealed with proper CI tooling. In your build script you can create one folder for each website, tweak it as needed and deploy each of them independently. With Google Cloud Build you can even deploy them in parallel.
- dawnerd 6y agoYeah if been meaning to setup something like that. Was thinking a base docket image that has all the shared stuff and just mounting the different directories for each site to override. Just haven’t had time.
- wdb 6y agoWould this approach leak the other domains associated with the Next.js site?
- avipars 6y agolanguages refer to i18n and not programming languges
- agustif 6y agoFunny because I thought it was programming langugages, as I have done that in the past. You can mix any supported /api serverless functions runtime in your backend code. I've done so with python and node for example. Gotta love next
- avipars 6y agolanguages refer to i18n and not programming languages
- avipars 6y agoPlease stop downvoting, I barely have any karma and I don't know how to delete this... I am aware that I posted the same comment twice accidentally.
- colejohnson66 6y agoFor future reference, to delete a comment, tap/click the “x minutes ago” time and then tap/click “delete” at the top. However, after two hours or after a single reply, you can no longer delete the comment.
- gigel82 6y agoThe biggest thing missing for i18n is `next export` support; that's the only way to get true SSR (static exports) for something like GitHub pages. It's a shame they haven't addressed that in months despite lots of folks asking for it.
- darkteflon 6y agoI ran into this (surprising) problem. Ended up having to shift my deployment from Netlify to Vercel itself to get around it.