Open rafapsm opened 2 weeks ago
Hi,
Despite these changes, when I try to deploy the apps on Heroku, they don't run correctly.
This is too vague to know what might be the issue. Please exactly define what you mean by "don't run correctly":
Hey @michaelbromley !
The error is that dist folder is not being generated. And this happens on both apps (Admin UI and API)
Cannot find module '/app/dist/index-worker.js'
(...)
Error: Cannot find module '/app/dist/index.js'
Hi,
Despite these changes, when I try to deploy the apps on Heroku, they don't run correctly.
This is too vague to know what might be the issue. Please exactly define what you mean by "don't run correctly":
- are there errors logged?
- do you not get the expected response from API requests?
- something else?
Hey @michaelbromley !
The error is that dist folder is not being generated. And this happens on both apps (Admin UI and API)
Cannot find module '/app/dist/index-worker.js' (...) Error: Cannot find module '/app/dist/index.js'
can you share a minimal reproduction repo?
Hi,
I'm working on decoupling the Admin UI and API in our project and deploying them as separate apps on Heroku using the same repository. I have made some changes to the setup, but I encountered issues when trying to deploy. The apps don't seem to run correctly on Heroku.
Here’s what I’ve done so far:
Original Setup: Previously, the AdminUiPlugin was initialized directly in the vendure-config.ts file.
Changes Made:
I moved the initialization logic of the AdminUiPlugin from the vendure-config.ts to a new file named compile-admin-ui.ts. The goal was to separate the build process for the Admin UI from the API, allowing them to be deployed independently.
vendure-config.ts
compile-admin-ui.ts
I also updated the build scripts in the package.json to ensure they handle the separate build processes for the Admin UI and the API.
package.json
build.js
Despite these changes, when I try to deploy the apps on Heroku, they don't run correctly. It seems like the build and deployment processes are not functioning as intended.
Any insights or advice on how to resolve these issues would be greatly appreciated!
Thank you.