Comments (10)
same issue. Any solution?
from apnagent.
I can't say that I've tried OpenShift, but I've been using Heroku without
any issues for a few months.
Can you post some example code on how you construct your agent object?
On Tue, Oct 13, 2015 at 8:53 PM, Phaninder Pasupula <
[email protected]> wrote:
same issue. Any solution?
—
Reply to this email directly or view it on GitHub
#35 (comment)
.
from apnagent.
same issue, Exactly same error activating gear
from apnagent.
This might help: https://developers.openshift.com/en/node-js-environment-variables.html
from apnagent.
Thank you @ajostergaard for quick reply , i have tried your solution it is working perfectly . But when i include package body-parser and morgan , it results the same error
my code:
var express = require('express');
var bodyParser=require('body-Parser');
var morgan=require('morgan');
var app = express();
var http = require('http');
app.use(bodyParser.urlencoded({extended:true}));
app.use(bodyParser.json());
app.use(morgan('dev'));
app.get('/', function (req, res) {
res.send('Hello World!');
});
var ipaddress = process.env.OPENSHIFT_NODEJS_IP;
var port = process.env.OPENSHIFT_NODEJS_PORT;
if(typeof ipaddress === "undefined"){
ipaddress = "127.0.0.1";
port = 3000;
}
app.listen(port, ipaddress, function() {
// Do your stuff
console.log("Your server is running on: "+ipaddress+" port:"+port);
});
if i comment out all the packages excluding express, it works fine ...
from apnagent.
@IAMDANGEROUS I suggest making sure it works locally before trying it on openshift however clearly not an apnagent issue.
@kommancs96 i suggest closing this issue.
from apnagent.
well its working 100% fine in local machine, please look at this post (the answer) , i want to know is there any to use node version 0.12.X , i mean the latest version in server side (on openshift), i think may be node 0.10 (running on openshift) doesn't support latest packages, thats why i am this issue
from apnagent.
Be that as it may this has nothing to do with apnagent.
Have you tried node 10 on your local machine?
from apnagent.
@ajostergaard thanks for keeping patience , and helping me everytime, i am an idiot, i was ignoring it all the time ,it was my silly mistake my 2nd line of code -->var bodyParser=require('body-Parser');<-- this was creating issue, i was importing wrong package all the time the package should be 'body-parser' (case-sensitive) ..
Now , everything is working fine locally and remotely . Again thanks for your help .
from apnagent.
most of the times this issue occurs because of the error in scripts or compilation silly human errors :)
from apnagent.
Related Issues (20)
- Where is 'error mitigation' section HOT 1
- TypeError: value is out of bounds HOT 1
- Queue is never restarted after SSL error HOT 7
- Agents randomly stop reconnecting HOT 1
- Consistent memory leaks HOT 6
- Gateway sporadically stops sending notifications HOT 3
- sending push in bulk HOT 3
- Site Down HOT 3
- Change to APNS HOT 1
- Sending push notifications in production environment not working HOT 2
- node agent/_header.js HOT 1
- Seeking Maintainer
- Decoder Stream 11 not implemented HOT 9
- APN agent connected coming false HOT 2
- Notification not received when device come from offline to online HOT 2
- sending MDM push notification to APNS
- does not accept "title" as part of the "alert" HOT 5
- Increment Badge Count HOT 1
- Collapse-id HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apnagent.