-
Notifications
You must be signed in to change notification settings - Fork 392
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bcrypt-node issue #834
Comments
Very odd. The auto-installer should have taken care of this. Did you install manually or something? https://github.com/jhuckaby/Cronicle/blob/master/docs/Setup.md#installation Looks like somehow the If you installed manually by hand, looks like perhaps a step was missed: mkdir -p /opt/cronicle
cd /opt/cronicle
curl -L https://github.com/jhuckaby/Cronicle/archive/v1.0.0.tar.gz | tar zxvf - --strip-components 1
npm install # <-- This step here
node bin/build.js dist Can you try the |
No buddy, i used this command after installing requirements. curl -s https://raw.githubusercontent.com/jhuckaby/Cronicle/master/bin/install.js | node |
That's really strange. Check the install log for errors maybe? cat /opt/cronicle/logs/install.log Also, check the ls -l /opt/cronicle/node_modules/bcrypt-node
total 120
-rw-r--r-- 1 root wheel 1481 Nov 11 2022 LICENSE
-rw-r--r-- 1 root wheel 4371 Nov 11 2022 README.md
-rw-r--r-- 1 root wheel 25423 Nov 11 2022 bCrypt.js
-rw-r--r-- 1 root wheel 248 Nov 11 2022 makefile
-rw-r--r-- 1 root wheel 1262 Nov 11 2022 package.json
drwxr-xr-x 4 root wheel 128 Nov 11 2022 test
-rw-r--r-- 1 root wheel 1463 Nov 11 2022 test-async.js
-rw-r--r-- 1 root wheel 4108 Nov 11 2022 test-sync.js Not sure what else to try. I've never encountered NPM failing to install bcrypt before. Maybe try running the install command again? |
Perhaps it just trying and failing to install some native modules (not using pre-built binaries). You can try to init some blank npm project "npm init -y" and try to install bcrypt there tocheck for errors. You might be missing python or gcc compiler |
I get this error for mikes reply.
|
Ah, here's our problem:
So when you installed Node.js, somehow the NPM binary didn't get installed. It's supposed to come with Node.js, but in this case it didn't go in for some reason. Try reinstalling Node.js from a package manager maybe? curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
sudo apt install -y nodejs This should install NPM as well as Node.js. |
After running
I got
|
Sorry, I should have clarified. Since Node.js wasn't properly installed on your server (until now), you will have to start over at the beginning, because none of the dependencies were installed by NPM. So, please try the Cronicle install steps one last time: curl -s https://raw.githubusercontent.com/jhuckaby/Cronicle/master/bin/install.js | node Then run the setup: /opt/cronicle/bin/control.sh setup Then finally you can start the service: /opt/cronicle/bin/control.sh start https://github.com/jhuckaby/Cronicle/blob/master/docs/Setup.md#installation Sorry this is so confusing. I'll try to make this all easier in v2. |
I got from jhuckaby
|
Oh dear god, of course. It thinks the latest is installed (it was "half-installed"), so it doesn't try to reinstall, UGH!!!! What a mess, I'm so sorry 😞 I think we'll need to wipe out the install, so it reinstalls from scratch. If you have customized the sudo cp /opt/cronicle/conf/config.json /tmp/ Then wipe it all out:
Then finally, you can do the reinstall steps, from the top: https://github.com/jhuckaby/Cronicle/blob/master/docs/Setup.md#installation Then you can copy your temp config file back into place, if needed: sudo mv /tmp/config.json /opt/cronicle/conf/config.json I'm SO sorry this is so confusing and silly. I will work on improving these installation steps and rewrite the installation documentation, with full Node.js install steps included, so people won't run into this situation in the future. Huge apologies. |
Worked. Legend thank you. |
Okay, so this looks like an issue with your
I don't know anything about this, but I'm guessing it's some sort of headless browser automation system akin to Puppeteer or Playright? I threw this over to ChatGPT 4o to get some more insight:
export DISPLAY=:0
firefox-esr Good luck! |
If the job ran successfully in the past, I am guessing that Cronicle was previously started with the Adding https://github.com/jhuckaby/Cronicle/blob/master/docs/Configuration.md#job_env |
Summary
Getting this error on Debian 12
/opt/cronicle/bin/control.sh setup
node:internal/modules/cjs/loader:1137
throw err;
^
Error: Cannot find module 'bcrypt-node'
Require stack:
at Module._resolveFilename (node:internal/modules/cjs/loader:1134:15)
at Module._load (node:internal/modules/cjs/loader:975:27)
at Module.require (node:internal/modules/cjs/loader:1225:19)
at require (node:internal/modules/helpers:177:18)
at Object. (/opt/cronicle/bin/storage-cli.js:12:14)
at Module._compile (node:internal/modules/cjs/loader:1356:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1414:10)
at Module.load (node:internal/modules/cjs/loader:1197:32)
at Module._load (node:internal/modules/cjs/loader:1013:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:128:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [ '/opt/cronicle/bin/storage-cli.js' ]
}
Steps to reproduce the problem
/opt/cronicle/bin/control.sh setup
Your Setup
NodeJs installed.
bcrypt installed.
Operating system and version?
Debian 12
Node.js version?
Node.js v18.19.0
Cronicle software version?
Single server
Are you using the filesystem as back-end storage, or S3/Couchbase?
No
Can you reproduce the crash consistently?
yes
Log Excerpts
The text was updated successfully, but these errors were encountered: