drone / drone-wall

Dashboard for the Drone CI server
260 stars 45 forks source link

Could not retrieve Drone status. #36

Closed cloudlena closed 8 years ago

cloudlena commented 8 years ago

I'm getting "Could not retrieve Drone status.". when accessing drone-wall. Before I entered the API root path and the token. If I enter the Drone root path (https://ci.berndsgn.ch/api/) into the browser and append "user/feed", it returns a JSON object so it should be valid and working... I'm using drone-wall as a docker image and Drone from the Rancher catalog in version 0.4-rancher2.

Tathanen commented 8 years ago

Your API path doesn't work for me, is it possible it's only accessible via certain machines or networks, and not where you have the Drone Wall installed?

cloudlena commented 8 years ago

Sorry for the confusion, @Tathanen. I deleted that drone instance in the mean time. That's why it's not reachable anymore. It was however running on the same host as the drone-wall instance. Right now I have one running at https://ci.zeilenwerk.ch/.

Tathanen commented 8 years ago

Could you look in your browser debug console, in the Network tab, and tell me what you're seeing for requests to user/feed? There should be a fresh one every few seconds. The "could not retrieve drone status" message comes when the request receives a 4XX/5XX HTTP response.

cloudlena commented 8 years ago

Good idea. It seems to be a CORS issue since the browser's console logs XMLHttpRequest cannot load https://ci.zeilenwerk.ch/api/user/feed. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://46.101.201.153:3001' is therefore not allowed access.

The XHR requests to https://ci.zeilenwerk.ch/api/user/feed return a status of 200.

Tathanen commented 8 years ago

Ah, yeah looks like the OPTIONS request fails on CORS then. Not much I can do about that from my end, @bradrydzewski any idea why a drone install might be putting up a CORS fuss for the wall?

bradrydzewski commented 8 years ago

drone adds Access-Control-Allow-Origin: * to all requests by default as well as a few other headers. In fact I believe we resolved a similar error back in February before the new version of the wall was launched https://github.com/drone/drone-wall/issues/30#issuecomment-180562166

so if I had to hypothesize why this error is occurring it would be:

the question I have is why isn't everyone getting this error? either everyone should be getting it, or nobody should be getting it.

Tathanen commented 8 years ago

Thanks @bradrydzewski. @mastertinner I'm not super familiar with Rancher, could you find out if it's installing an older version of Drone? One from before this issue was resolved earlier this year?

cloudlena commented 8 years ago

The version of Drone in the Rancher catalog seems to be pretty outdated indeed... Thanks for your help guys, I'll try to get that updated or use the official Drone image instead.

Bothees commented 4 years ago

Hi, am running latest Drone server and runner docker on my local Mac machine and tried to setup drone-wall.

Drone server & runner working as expected, picking up the build and running. when I connect to the Drone-wall, I am getting "Could not retrieve Drone status" and when I look at the Network tab I can see 404 error code for /api/user/feed request. Can someone help me what am I missing here?

Screenshot 2020-09-07 at 12 47 54
tboerger commented 4 years ago

This never had been updated to recent drone versions.

Bothees commented 4 years ago

Hi Thomas, Thank you so much for the answer. I am trying to setup Build Monitor for my repo,

What are the options available if Drone-wall is not updated for the recent versions ?

Are there any Plugins available ?

Please help me with setting up the Dashboard. Thanks.

tboerger commented 4 years ago

I don't know about any tool like this wall.

Bothees commented 4 years ago

No Problem Tom. what I should do to bring up the Drone-wall for the latest version of Drone?

tboerger commented 4 years ago

The API Endpoints got to be updated, maybe you could also simply start using https://github.com/drone/drone-node which gets published as an NPM package.

Bothees commented 4 years ago

Hi Tom, Sorry to bother you again. So I just want to double check,

use this drone-node to pull the data from drone-server and display it on the wall right? Sorry if my my questions are silly.

Is there any UI component where I can reuse with drone-node? Thanks

tboerger commented 4 years ago

drone-node does not provide any UI component. You are right, you can use drone-node to fetch the relevant data from any Drone server.

Bothees commented 4 years ago

Perfect Thanks Tom. I Just don't want to re-invent the wheel, By any chance do you know anyone been using Drone-node to fetch the data and display it on a dashboard. If you could let me know I can contact and get the details.

Thank you so much for all the replies.

Bothees commented 3 years ago

Hi Tom, I managed the use Drone-node and pulled the data to display on the wall. I just had one question to double check,

It used to be the end-point,

/api/user/feed

is it the equivalent in the latest is,

/api/user/builds

Thanks, Bothi