Scale up as you grow — whether you're running one virtual machine or ten thousand.

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.

I am setting up an App Platform on Digital Ocean using a Strapi web service component as CMS and a Next.js web service component as Front-End. Strapi is accessible on the route /api and Next.js on /sporus. According to the runtime logs building and deployment are both successful and no errors are shown. When I try to access my Next.js web service through the route /sporus I am met with a 404 screen. Strapi on /api is working including the admin panels and requests.
Next.js Webservice is accessible through the /sporus route and does not return a 404.
##What I’ve tried
npm run start to next start -H 0.0.0.0 -p ${PORT:-8080} according to two guides by Digital Ocean tutorial(https://www.digitalocean.com/community/tutorials/how-to-deploy-a-next-js-app-to-app-platform) video(https://youtu.be/1ldjq5M7cbw?t=363).basePath: process.env.BASE_PATH to next.config.js according to the Next.js docsconst domains = (process.env.APP_URL) ? [process.env.APP_URL] : ['localhost'];
module.exports = {
reactStrictMode: false,
images: {
domains: domains,
},
basePath: process.env.BASE_PATH,
}
App wide:
- key: STRAPI_URL
scope: RUN_AND_BUILD_TIME
value: ${APP_URL}/api
- key: NEXT_PUBLIC_STRAPI_URL
scope: RUN_AND_BUILD_TIME
value: ${APP_URL}/api
- key: DATABASE_URL
scope: RUN_AND_BUILD_TIME
value: ${db.DATABASE_URL}
- key: APP_URL
scope: RUN_AND_BUILD_TIME
value: ${APP_URL}
Next component specific:
key: NEXT_URL
scope: RUN_AND_BUILD_TIME
value: ${APP_URL}/sporus
- key: BASE_PATH
scope: RUN_AND_BUILD_TIME
value: /sporus
I have very experience with D.G. App Platform & Next.js or deploying node.js servers in general. Most of my projects I run locally so I apologise if this question isn’t very descriptive. All additional debugging steps or general tips are welcome.
KFSys
KFSys
Manuel Maldonado
07ffbf0c7e1b47f4b26636bc7104f4
Solomon
Jopce
JipSterk
Mireya Leon
ITTI Nepal
alunlewis
Bartek Pacia