HI. We’ve been using the standard community version for a few years (and have a healthy Mongo db full of posts). I would like to setup a DEV environment using the latest Git repo source code but populate that DEV env with a copy of my production db. Basicly, how do I build the system from the source code, then deploy that code to use my copy of the production db?
My question is really around “replacing” the standard build with a new build. I’m not super familiar with NPM and Meteor yet, so the various steps for building are still foreign to me right now. Here are the steps I’ve used to simply install RC for the past couple of years: Rocket.Chat in Ubuntu - Rocket.Chat Docs. Here is what I’ve played with in cloing the repo and doing a build for it:https://developer.rocket.chat/guides/developer/quick-start-on-linux
If I use the repo clone/build steps, that seems to use .meteor/local/db for the path to the mongo db, and I’ve not been successful in getting that build up and running with the copy of my production db. Those build steps do a “meteor npm start”, which runs its own Mongo server (based on what I see in a ps -ef display). I’d love to get that “repo build” simply moved and running like I do with the “manual build steps” in the first doc above, which starts mongod and rocketchat as services.
I need to go find the brains department and get you some help!! Might be quiet as it is the weekend so could be Monday.
At least for now get the thing running and you can test on a fresh DB - I think your hands are going to be full finding your way around Meteor I believe!!
My setup is a regular Ubuntu and Apache setup where Mongo and RC run as services. Part of what I’m trying to figure out is how to “build” the RC application code from a Git clone (then modified) so I can simply run it in in the same Ubuntu/Apache setup where Mongo and RC are run as services. I can successfully dump and restore a Mongo db in that kind of setup. For building the app itself, the instructions and shell script examples in the Git repo show samples of runing the app in several setups, but not the one I describe.
My next question is exactly what meteor does when it “builds”. For example, if I pull a new copy of the repo and execute these commands, all is well. If I then simply run the script again (i.e., rebuild the app again), it dies when running the “meteor --allow-superuser build --server-only” command with this output (is there a folder I need to wipe out before “rebuilding”?):
SyntaxError: Unexpected token u in JSON at position 1
at JSON.parse ()
at /home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/fs/tools/fs/optimistic.ts:321:17
at wrap.makeCacheKey (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/fs/tools/fs/optimistic.ts:36:15)
at recomputeNewValue (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/entry.ts:182:31)
at Slot.withValue (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/@wry/context/lib/context.js:73:29)
at reallyRecompute (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/entry.ts:165:19)
at Entry.recompute (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/entry.ts:85:9)
at optimistic (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/index.ts:101:25)
at /home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/fs/tools/fs/optimistic.ts:366:19
at recomputeNewValue (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/entry.ts:182:31)
at Slot.withValue (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/@wry/context/lib/context.js:73:29)
at reallyRecompute (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/entry.ts:165:19)
at Entry.recompute (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/entry.ts:85:9)
at optimistic (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/optimism/src/index.ts:101:25)
at find (/tools/isobuild/package-source.js:1339:30)
at /tools/isobuild/package-source.js:1395:27
at Array.forEach ()
at find (/tools/isobuild/package-source.js:1374:22)
at /tools/isobuild/package-source.js:1395:27
at Array.forEach ()
at find (/tools/isobuild/package-source.js:1374:22)
at find (/tools/isobuild/package-source.js:1406:25)
at /tools/isobuild/package-source.js:1395:27
at Array.forEach ()
at find (/tools/isobuild/package-source.js:1374:22)
at find (/tools/isobuild/package-source.js:1374:22)
at /tools/isobuild/package-source.js:1395:27
at Array.forEach ()
at find (/tools/isobuild/package-source.js:1374:22)
at /tools/isobuild/package-source.js:1395:27
at Array.forEach ()
at find (/tools/isobuild/package-source.js:1374:22)
at /tools/isobuild/package-source.js:1395:27
at Array.forEach ()
at find (/tools/isobuild/package-source.js:1374:22)
at /tools/isobuild/package-source.js:1418:34
at Object.withCache (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/fs/tools/fs/files.ts:1663:18)
at PackageSource.findSources (/tools/isobuild/package-source.js:1418:18)
at SourceArch.getFiles (/tools/isobuild/package-source.js:960:32)
at /tools/isobuild/compiler.js:406:23
at /tools/isobuild/compiler.js:186:28
at Object.withCache (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/fs/tools/fs/files.ts:1663:18)
at /tools/isobuild/compiler.js:185:11
at Function..each._.forEach (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/underscore/underscore.js:186:9)
at Object.compile (/tools/isobuild/compiler.js:180:5)
at /tools/isobuild/bundler.js:3268:24
at Object.capture (/tools/utils/buildmessage.js:283:5)
at bundle (/tools/isobuild/bundler.js:3214:31)
at /tools/isobuild/bundler.js:3157:32
at Slot.withValue (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/@wry/context/lib/context.js:73:29)
at Object.withCache (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/fs/tools/fs/files.ts:1663:39)
at Object.bundle (/tools/isobuild/bundler.js:3157:16)
at buildCommand (/tools/cli/commands.js:1082:30)
at /tools/cli/commands.js:945:25
at Function.run (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/tools/tool-env/tools/tool-env/profile.ts:289:14)
at /tools/cli/commands.js:943:18
at /home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/meteor-promise/fiber_pool.js:43:40
=> awaited here:
at Promise.await (/home/ubuntu/.meteor/packages/meteor-tool/.2.1.1.ixi3z9.hw65m++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/lib/node_modules/meteor-promise/promise_server.js:60:12)
at /tools/cli/main.js:1529:7