Remove Heroku setting from Hubot? - heroku

I tried running Hubot on Heroku, but I gave up because I'd prefer not to give out my credit card number.
Instead, I tried running Hubot on my mac. It gave an error, like this:
$ ./bin/hubot
hubot-sample> [Fri Jun 05 2015 11:41:52 GMT+0900 (JST)] ERROR hubot-heroku-alive included, but missing HUBOT_HEROKU_KEEPALIVE_URL. `heroku config:set HUBOT_HEROKU_KEEPALIVE_URL=$(heroku apps:info -s | grep web_url | cut -d= -f2)`
[Fri Jun 05 2015 11:41:52 GMT+0900 (JST)] INFO Using default redis on localhost:6379
I think this error occured because Hubot is looking for Heroku. How do I remove this?

Try this.
cd <your-hubot-project-dir>
npm uninstall hubot-heroku-keepalive --save
Then find and remove the line that contains "hubot-heroku-keepalive" from file "external-scripts.json".
Run "bin/hubot" again.

Related

When rsyslog (v8.39.0) mmnormalize is not recognized. How can this be fixed?

I am trying to use mmnormalize to structure text logs. Both with rsyslog 8.16.x and with 8.39.0 when trying to use mmnormalize as an action logs show that the module was not recognized. Below are details.
How can I set up to use mmnormalize with rsyslog?
remediation already tried
Installed separately liblognorm, libstr, json-c,libfastjson
Upgraded rsyslog from 8.16.x to 8.39.0
rsyslog .conf
module(load="mmnormalize") # text parsing
syslog log messages
Dec 3 11:33:55 sys1 systemd[1]: Starting System Logging Service...
Dec 3 11:33:55 sys1 systemd[1]: Started System Logging Service.
Dec 3 11:33:55 sys1 rsyslogd: could not load module 'mmnormalize',
errors: trying to load module /usr/lib/rsyslog/mmnormalize.so:
/usr/lib/rsyslog/mmnormalize.so: cannot open shared object file: No
such file or directory [v8.39.0 try http://www.rsyslog.com/e/2066 ]
Dec 3 11:33:55 sys1 rsyslogd: module name 'mmnormalize' is unknown
[v8.39.0 try http://www.rsyslog.com/e/2209 ]
Dec 3 11:33:55 sys1 rsyslogd: error during parsing file
/etc/rsyslog.d/52-tomcat.conf, on or before line 52: errors occured in
file '/etc/rsyslog.d/52-tomcat.conf' around line 52 [v8.39.0 try
http://www.rsyslog.com/e/2207 ]
The following way to install mmnormalize worked for me. I was running this on Ububutu (Xenial)
sudo apt-get install rsyslog-mmnormalize
Rich Megginson (thank you) answered as below to the same question I posted to rsyslog mailing list (rsyslog#lists.adiscon.com). As mentioned above it worked for me.
"On RHEL/CentOS/Fedora and similar platforms, the rsyslog-mmnormalize is a separate RPM that must be installed separately e.g.
yum install rsyslog rsyslog-mmnormalize ....
"

firebase deploy Hangs in Terminal

I am trying to upload a project to Firebase hosting. I recently reinstalled macOS Sierra, so have fresh installs of Node and firebase-tools.
However, I get the following error when running firebase deploy --debug
[2017-08-10T21:54:40.043Z] --------------------------------------------
--------------------------
[2017-08-10T21:54:40.046Z] Command:
/usr/local/bin/node/usr/local/bin/firebase deploy --debug
[2017-08-10T21:54:40.047Z] CLI Version: 3.9.2
[2017-08-10T21:54:40.047Z] Platform: darwin
[2017-08-10T21:54:40.047Z] Node Version: v8.3.0
[2017-08-10T21:54:40.048Z] Time: Thu Aug 10 2017 16:54:40 GMT-
0500 (CDT)
[2017-08-10T21:54:40.048Z] --------------------------------------------
--------------------------
[2017-08-10T21:54:40.058Z] > command requires scope:["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform”][2017-08-10T21:54:40.059Z] > authorizing via signed-in user
[2017-08-10T21:54:40.061Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/projects/dornfeld-design
Thu Aug 10 2017 16:54:40 GMT-0500 (CDT)
[2017-08-10T21:54:40.471Z] <<< HTTP RESPONSE 200 server=nginx, date=Thu, 10 Aug 2017 21:54:40 GMT, content-type=application/json; charset=utf-8, content-length=121, connection=close, x-content-type-options=nosniff, strict-transport-security=max-age=31536000; includeSubdomains, cache-control=no-cache, no-store
[2017-08-10T21:54:40.472Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/database/name-of-project/tokens
Thu Aug 10 2017 16:54:40 GMT-0500 (CDT)
[2017-08-10T21:54:41.061Z] <<< HTTP RESPONSE 200 server=nginx, date=Thu, 10 Aug 2017 21:54:40 GMT, content-type=application/json; charset=utf-8, content-length=429, connection=close, x-content-type-options=nosniff, strict-transport-security=max-age=31536000; includeSubdomains, cache-control=no-cache, no-store
Whats the best way to proceed forward? I have tried reinstalling firebase-tools with 3 different versions of Node.
Additional comments:
had to install firebase-tools with --unsafe-perm command to get it to install.
firebase init only created .firebaserc file and a firebase.json file with {}
Manually created firebase.json file with proper public folder, etc.
Steps taken to correct problem
Uninstall Node cd /usr/local/lib
sudo rm -rf node_modules
Install Homebrew /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Install Yarn brew install yarn
Install Firebase CLI yarn add firebase-tools
Go to project folder, firebase login, firebase init
a. init creates .firebaserc file correctly
b. firebase.json still blank, i.e. {}
Create firebase.json manually:
{
"hosting": {
"public": "build/unbundled",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"rewrites": [{
"source": "**",
"destination": "/index.html"
}]
}
}
firebase deploy now works properly.

MEAN.IO Slack.js error

I've installed MEAN.IO as in the instructions here: http://mean.io/#!/docs
Along the lines I did see some errors in the installation process and I had to manually install grunt-cli globally.
When I create a testapp and run grunt then this is my output:
MEAN:~/testApp$ grunt
Running "clean:0" (clean) task
Running "jshint:all" (jshint) task
packages/slack/server/routes/slack.js
2 |var posts = require("../controllers/posts");
^ Strings must use singlequote.
11 | });
^ Missing semicolon.
11 | });
^ Expected an identifier and instead saw ')'.
11 | });
^ Expected an assignment or function call and instead saw an expression.
22 |};
^ Expected '(end)' and instead saw '}'.
14 | app.get('/slack/all', auth.requiresLogin, function(req, res, next){
^ 'app' is not defined.
14 | app.get('/slack/all', auth.requiresLogin, function(req, res, next){
^ 'auth' is not defined.
15 | Slack.render('index', {
^ 'Slack' is not defined.
>> 8 errors in 47 files
Warning: Task "jshint:all" failed. Use --force to continue.
Aborted due to warnings.
What's going wrong here?
For completeness here are my versions:
MEAN:~/testApp$ mean -v && npm -v && node -v
0.5.7
1.4.14
v0.10.29
I am very new to the MEAN.io framework and just install it and got the same error. The simplest way around it seems to be running the following in the root directory of the app.
mean package -d slack
then
mean package slack
Fixed it for me. Seems there was an update 6 hours ago.
Jay is correct. You can see this commit https://github.com/linnovate/mean/commit/433609f295dc4377882998e7e811c9a307bcbe89 that slack has been removed from the project.
You have 3 ways to correct the issue.
git pull upstream master to get the new updates
Do as Jay suggested by removing the slack package
Create a clean project with mean init myApp

hg-git deploy to heroku from Lion

I have this application on my Lion machine that is in a mercurial repository so I'm using hg-git to deploy it to heroku.
~/.hgrc
[extensions]
hgext.bookmarks =
hggit =
.../project/.hg/hgrc
[paths]
default = https://validhgrepo.com
[alias]
push-heroku = push git+ssh://git#heroku.com:appname.git
Then when I run hg push-heroku it should deploy, but instead I get:
caseys-MacBook-Air:project casey$ hg push-heroku
pushing to git+ssh://git#heroku.com:appname.git/
creating and sending data
["git-receive-pack 'appname.git/'"]
! Invalid path.
! Syntax is: git#heroku.com:<app>.git where <app> is your app's name.
abort: git remote error: The remote server unexpectedly closed the connection.
This doesn't make any sense. I feel like the error message is misleading because that repository DOES exist.
Also this works perfect on my ubuntu machine with a similar setup.
Turns out this was related to this issue. I hadn't noticed the extra slash before. I applied a patch similar to this guy and it worked for me (on latest hg, hg-git and osx).
Full details of how to install the patch:
first uninstall it
sudo easy_install -m 'hg-git'
then delete the hg-git egg file in ~/Library/Python/2.7/site-packages
install as directory
sudo easy_install -Z 'hg-git'
open ~/Library/Python/2.7/site-packages/hg_git..../hggit/git_handler.py
apply patch by hand (mine was more like line 1118)
--- git_handler.py Thu Jul 28 22:05:45 2011
+++ patched.git_handler.py Thu Jul 28 22:11:44 2011
## -1066,6 +1066,8 ##
port = None
host, path = hostpath.split(hostpath_seper, 1)
+ if (host.find('heroku') > 0):
+ path = path.rstrip('/')
if hostpath_seper == '/':
transportpath = '/' + path
else:
Your git remote format is screwed.
In .git/config ensure that your remote takes the format of:
git#heroku.com:appname.git
where appname is your applications name on Heroku

Error with resque-web: Couldn't get a file descriptor referring to the console

I'm trying start resque-web, but this error occurs:
[Sun Mar 06 05:27:48 +0000 2011] Starting 'resque-web'...
[Sun Mar 06 05:27:48 +0000 2011] trying port 8281...
Couldn't get a file descriptor referring to the console
This error occurred with Ubuntu 10.04 and 10.10.
Resque Web only starts with -F option (don't daemonize, run in the foreground). So, it must be something when the process is daemonized.
Any idea, how can I solve it?
Regards,
It's probably trying to open the default browser and failing to do so. Try using:
$ resque-web -L
To avoid starting a browser.

Resources