Parse-Dashboard - server not reachable unable to connect to server - parse-server

I am trying to install Parse-Server and Parse-Dashboard in Google Cloud (Debian/Jesse). I have already installed on both Windows (locally) and on Heroku and everything worked fine.
My configuration is the following:
Linux Debian 3.16.43-2
Node JS 7.10
Mlab
Firewall Ports are open
Installed both Parse-Server and Dashboard via npm.
I think Parse-Server is running fine since I was able to check that MLab database was written with Parse-Server tables (_SCHEMA, etc).
My Parse Dashboard config file is the following:
{
"apps": [
{
"serverURL": "http://localhost:1337/parse",
"appId": "1",
"masterKey": "654321",
"appName": "AppName",
"production": "true"
}
],
"users": [
{
"user":"username",
"pass":"password"
}
]
}
I run parse-server with this command and it shows the following status:
parse-server --appId 1 --masterKey 654321 --databaseURI mongodb://dbAdmin:db123456#Omitted.mlab.com:Omitted/Omitted --serverURL http://127.0.0.0.1/ --port 1337 --appName AppName
appId: 1
masterKey: ***REDACTED***
port: 1337
host: 0.0.0.0
databaseURI: mongodb://dbAdmin:db123456#Omitted.mlab.com:Omitted/Omitted
serverURL: http://127.0.0.0.1/
mountPath: /parse
appName: AppName
maxUploadSize: 20mb
userSensitiveFields: ["email"]
I run parse-dashboard with this command and it shows the following status:
parse-dashboard --config /usr/local/lib/node_modules/parse-dashboard/Parse-Dashboard/parse-dashboard-config.mine.json --allowInsecureHTTP
The dashboard is now available at http://0.0.0.0:4040/
I am able to log into Dashboard but it keeps saying:
server not reachable unable to connect to server.
I have tried the following list of fixes:
Changed serverURL to localhost or to 127.0.0.1
Added /parse at the end of the address
Changed serverURL port to 1333
Checked APP ID, APP Masterkey and APP Name
Opened firewall ports
Stopped using configuration file
Nothing solves this problem. If anyone has any suggestion, I would very be pleased to try.
Thanks in Advance.
Regards,
James P

Problem solved. Probably this is not the correct solution, but at least it worked.
The serverURL: http://127.0.0.0.1/ or serverURL: http://localhost/ did not work for me. I have changed both parse-server and parse-dashboard to an external IP for (35.x.x.x, in my case).

I faced the same problem.
Configuration:
Installed mongodb, parse-server & parse-dashboard, all 3 on separate docker instances.
Used a 4th docker instance with apache2 to make it work as a reverse proxy.
Mistake:
Pointed subdomain parse-dashboard.ABC.com to the parse-dashboard, but did not point parse-server to any subdomain. The most important part here is that parse-dashboard uses JavaScript to access app on parse-server, so this resulted in a CORS error.
Solution:
I pointed parse.ABC.com to parse-server.
Hope this helps someone.

Have you started mongodb?
sudo service
Did you start parse-server before Parse-Dashboard?
In your project folder
npm start
On another terminal in your project folder start Parse-Dashboard
Parse-dashboard --config parse-dashboard-config.json

Related

Find out version of Redis running in PCF DEV

How to find out which version of Redis is running in PCF DEV? I'm using the latest PCF DEV 1.2.0 for PAS 2.4.4 and created the service as per the docs, like this:
cf cs p.redis cache-small redis
It is running, and I have some app talking to it. Now I just want to know which version it is.
I found a way with the help of a colleague: First, find out the hostname, port and password by querying the environment of the application which is successfully connected to Redis with cf env [APP-NAME]. The relevant chunk looks like this:
"VCAP_SERVICES": {
"p.redis": [
{
"binding_name": null,
"credentials": {
"host": "q-s0.redis-instance.default.service-instance-deadbeef-8008.bosh",
"password": "THXQCcElifUCCbJD2RlU7tgjZegmkn",
"port": 6379
},
(...)
Now, SSH into the apps container with cf ssh [APP-NAME] and use Netcat to connect to Redis:
vcap#...:~$ nc q-s0.redis-instance.default.service-instance-deadbeef-8008.bosh 6379
Then use AUTH and the password to "login"...
AUTH THXQCcElifUCCbJD2RlU7tgjZegmkn
+OK
...and issue the INFO command - the Redis version is displayed right at the top:
INFO
$3365
# Server
redis_version:5.0.2
(...)
Anyway, this is likely very much work for a tiny bit of information - are there other ways?

Minishift: Could not resolve: *.192.168.64.2.nip.io

I have installed minishift on OSX with brew:
brew cask install minishift-beta
...
$ minishift version
Minishift version: 1.0.0
I have sucessfuly started minishift, and created node-ex example application and exported it:
$ oc get route
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD
nodejs-ex nodejs-ex-myproject.192.168.64.2.nip.io nodejs-ex 8080-tcp None
However I can not reach .192.168.64.2.nip.io:
$ curl nodejs-ex-myproject.192.168.64.2.nip.io
curl: (6) Could not resolve host: nodejs-ex-myproject.192.168.64.2.nip.io
$ dig +short nodejs-ex-myproject.192.168.64.2.nip.io
$
All is working with minishift web console and oc command, but I can not reach the application domain.
Thank you #enj. The explanation at http://nip.io is clear about how it works.
I have seen that queries to 8.8.8.8 and to my ISP DNS are resolved to my private IP. But it is my router (my primary DNS) which do respond nip.io
My router run DD-WRT and has enabled
Rebind protection Discard upstream RFC1918 responses
then I add nip.io at
Domain whitelist nip.io
and now I resolve queries:
≻ dig +short test.10.0.0.1.nip.io
10.0.0.1
Is something on your machine or network blocking DNS queries to nip.io?
When playing with Minishift at home, where I am connected to the internet via Deutsche Telekom's VDSL and Speedport-Router, I cannot resolve these xip.io or nip.io addresses.
My workaround is to put 8.8.8.8 into /etc/resolv.conf
I had the same issue on Windows 10. My workaround was to add an entry in C:\Windows\System32\drivers\etc\hosts file. Here is an example
192.160.90.101 nodejs-ex-nodejs-echo.192.160.90.101.nip.io # needed for minishift to work

Not able to open the deck UI for spinnaker

I installed spinnaker using the command
bash <(curl --silent https://spinnaker.bintray.com/scripts/InstallSpinnaker.sh)
on a local ubuntu machine.
After installation I am not able to connect to the Deck UI of spinnaker using URL: http://localhost:9000
Check logs in /var/log/apache2 for errors, and /etc/apache2/ports.conf to see if it is is listening on 127.0.0.1:9000
The install script should have made those changes for you, but maybe you had a permissions issue or some other kind of local system policy preventing the installation from working properly.

How can I set virtual host in Codeship?

I’m using Codeship to automate a multi-tenancy application.
My app need subdomain setting to run acceptance tests using Selenium Web Driver.
So, I need to config virtual domain for my app.
For example, I need the following virtual domain:
127.0.0.1 test.my-app.test
127.0.0.1 my-app.test
If I do not use subdomain to request to my app, It not work as requirement.
I tried the following commands in Setup Commands section before Test Pipelines.
sudo echo '127.0.0.1 test.my-app.test' >> /etc/hosts
sudo echo '127.0.0.1 my-app.test' >> /etc/hosts
But, It doesn’t work, because I has no permission. The error message was:
bash: /etc/hosts: Permission denied
Would you mind tell me how to make it work ?
Thank you in advanced !
Update:
I received reply from Codeship team:
this is not possible in our classic infrastructure due to technical limitations. You could move to our Docker Platform, which allows more customization of your build environment.
We need to use Docker to solve this issue
Your redirected command will not be executed in the root privilege, that's why you got the Permission denied error.
Your command means "do the echo in the privilege root, then redirected to /etc/hosts file".
Try this:
sudo sh -c 'echo "Your text" >> /path/to/file'
We don't allow access via sudo on the build VMs because of security considerations.
However, you can use a service like http://xip.io/ or lvh.me to access your application via DNS names.
$ nslookup codeship.lvh.me
Server: 8.8.8.8
Address: 8.8.8.8#53
Non-authoritative answer:
Name: codeship.lvh.me
Address: 127.0.0.1
lvh.me will resolve any requests to a subdomain to 127.0.0.1, xip.io offers more functionality, that is explained on its homepage in more detail.

Docker login error with Get Started tutorial

I'm trying to follow beginner tutorial on Docker's website and I suffer with an error on login.
OS is Ubuntu 14.04, I'm not using VirtualBox and I'm not behind any proxy and want to push to the "regular" docker repository (not private one).
All threads I've found mention proxies and private repositories but that isn't my case, I'm just trying to do simple beginner tutorial.
Here is my attempt:
$ sudo docker login
[sudo] password for myuname:
Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to https://hub.docker.com to create one.
Username: myDHuname
Password:
Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
My docker info:
Containers: 5
Running: 0
Paused: 0
Stopped: 5
Images: 5
Server Version: 1.11.0
Storage Driver: aufs
Root Dir: /var/lib/docker/aufs
Backing Filesystem: extfs
Dirs: 28
Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge null host
Kernel Version: 3.19.0-58-generic
Operating System: Ubuntu 14.04.4 LTS
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 7.686 GiB
Name: myuname-ThinkPad-T420
ID: 6RW3:X3FC:T62N:CWKI:JQW5:YIPY:RAHO:ZHF4:DFZ6:ZL7X:JPOD:V7EC
Docker Root Dir: /var/lib/docker
Debug mode (client): false
Debug mode (server): false
Registry: https://index.docker.io/v1/
WARNING: No swap limit support
Epilogue
Now docker login is passing. I have not touched anything since yesterday when it was broken...
I can't reproduce the behavior anymore.
I encounter this issue when my first use docker. I've shadowsocks proxy on, and configed as pac mode. When I try to run docker run hello-world, I get this timeout error. When I set the proxy mode to global, the error is aslo there.
But when I disable the proxy, docker runs well. It pull remote image successfully.
docker for windows
Note: Some users reported problems connecting to Docker Hub on Docker
for Windows stable version. This would manifest as an error when
trying to run docker commands that pull images from Docker Hub that
are not already downloaded, such as a first time run of docker run
hello-world. If you encounter this, reset the DNS server to use the
Google DNS fixed address: 8.8.8.8. For more information, see
Networking issues in Troubleshooting.
The error Client.Timeout exceeded while awaiting headers indicates:
GET request to the registry https://registry-1.docker.io/v2/ timedout
The library responsible (most likely libcurl) timed out before a response was heard
The connection never formed (proxy/firewall gobbled it up)
If you see the below result you can rule out timed out and network connectivity
$ curl https://registry-1.docker.io/v2/
{"errors":[{"code":"UNAUTHORIZED","message":"authentication required","detail":null}]}
If you get the above response next would be to check if your user environment has some proxy configuration.
env | grep "proxy"
Note: The docker runs as root. Maybe you have http_proxy in your env. Most likely I am wrong. Anywho see what happens with the curl GET request
change the proxy settings in the firefox. May be you are in access restricted mode. Just add the server address in the firefox settings -> preferences -> advanced -> network -> configuration (settings). Add the server ip in the no proxy for the issue can be resolved