eduardoboucas / staticman

💪 User-generated content for Git-powered websites
https://staticman.net
MIT License
2.41k stars 534 forks source link

Error: Require an `oauthToken` or `token` option #438

Open scbot1729 opened 2 years ago

scbot1729 commented 2 years ago

Here is the stack trace, what is wrong?

at /root/staticman/lib/GitHub.js:33:15 [20/1834] at new GitHub (/root/staticman/lib/GitHub.js:46:7)
at Object.module.exports.create (/root/staticman/lib/GitServiceFactory.js:11:14)
at /root/staticman/lib/Staticman.js:32:35 at new Staticman >>>...(/root/staticman/lib/Staticman.js:46:7)
at module.exports (/root/staticman/controllers/process.js:126:27) at Layer.handle [as handle_request] (/root/staticman/node_modules/express/l ib/router/layer.js:95:5) at next (/root/staticman/node_modules/express/lib/router/route.js:137:13)
at /root/staticman/server.js:169:14 at Layer.handle [as handle_request] (/root/staticman/node_modules/express/l ib/router/layer.js:95:5) at next >(/root/staticman/node_modules/express/lib/router/route.js:137:13) at /root/staticman/server.js:144:14 at Layer.handle [as handle_request] >>>(/root/staticman/node_modules/express/lib/router/layer.js:95:5) >at next (/root/staticman/node_modules/express/lib/router/route.js:137:13)
at /root/staticman/server.js:129:14 at Layer.handle [as handle_request] >(/root/staticman/node_modules/express/lib/router/layer.js:95:5)

Here is the config config.production.json

{ "githubToken": "XXX",
  "githubPrivateKey": " -----BEGIN RSA PRIVATE KEY----- xXX",
   "rsaPrivateKey": " -----BEGIN RSA PRIVATE KEY----- XXX",
   "port": 8080
}

And the staticman.yml is same as staticman.sample.yml

What am I doing wrong? I posted to

http://spamcheetah.com:8080/v3/entry/github/<bot>/<repo>/master/comments