13:31:27.190250 Starting admin server on 54.153.0.112:4985
13:31:27.196218 Starting server on 54.153.0.112:4984 ...
13:31:27.196368 FATAL: Failed to start HTTP server on 54.153.0.112:4985: listen tcp 54.153.0.112:4985: bind: cannot assign requested address -- rest.(*ServerConfig).serve() at config.go:392
[ec2-user@ip-172-31-14-232 sync_gateway
This is a RedHat EC2 instance.
Here is my config.json:
{
"interface":"54.153.0.112:4984",
"adminInterface":"54.153.0.112:4985",
"databases": {
"shotbotdb": {
"server": "http://54.153.0.112:8091",
"bucket": "sync_gateway",
"log": ["HTTP", "REST+", "CRUD", "Access"],
"users": {
"GUEST": {"disabled": true},
"xxxx": {"password": "xxx", "all_channels": ["xxxx"] }
},
"sync":`
function(doc, oldDoc) {
if (doc._deleted) {
if (oldDoc) {
requireUser(oldDoc.owner);
}
return;
}
if (oldDoc) {
requireUser(oldDoc.owner);
}
requireUser(doc.owner);
channel(doc.owner);
access(doc.owner, doc.owner);
}`
}
}
}
You will get that error if the server does not have a NIC configured with that IP address.
I'm not sure about EC2 but the 'ifconfig' command should show the configured interfaces.