Structure for serving Remix app (and other things) through CLI #8618
Unanswered
ostollmann
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi there,
I am trying to build/package a single Node app that can act as different things depending on the way it is invoked, e.g.:
node index.js app1 serve
: serve remix app called app1node index.js app2 serve
: serve remix app called app2node index.js db transfer d1.conn.json db2.conn.json
: run some headless programI specifically don't want multiple packages. Ideally the directory structure would be something like this with shared dependencies in a package.json:
I starting app1 or app2, the entry point would run the
runExpress
function defined inapp1/server.ts
orapp2/server.ts
.I have tried a couple of things, but haven't really gotten anywhere and would thus be very thankful for suggestions or pointers on how to setup a project like this. Some specific questions:
remix build
on different directories with a central package.json (npm run app(1|2):build
)?npm run app2:dev
do (remix dev
,txc watch
?)?Thanks!
Beta Was this translation helpful? Give feedback.
All reactions