parabuzzle / craneoperator

Gives you a simple web interface for browsing around a Docker Registry
https://hub.docker.com/r/parabuzzle/craneoperator
MIT License
127 stars 32 forks source link

Provide More Debug Information #21

Closed phauer closed 7 years ago

phauer commented 8 years ago

Hi, thanks for this promising project. Unfortunately, I don't see any registry content in the UI. There are only the loading indicators. In the Chrome Dev Tools Console I see the following errors:

bundle.js:20528 GET http://localhost:8080/containers.json 500 (Internal Server Error)xhrAdapter @ bundle.js:20528executor @ bundle.js:20377dispatchRequest @ bundle.js:20373
bundle.js:40705 Uncaught (in promise) TypeError: Cannot read property 'setState' of undefined
    at http://localhost:8080/bundle.js:40705:14(anonymous function) @ bundle.js:40705
bundle.js:20528 GET http://localhost:8080/container/undefined/tags.json 500 (Internal Server Error)xhrAdapter @ bundle.js:20528executor @ bundle.js:20377dispatchRequest @ bundle.js:20373
bundle.js:41445 Uncaught (in promise) TypeError: Cannot read property 'setState' of undefined(…)(anonymous function) @ bundle.js:41445

Maybe it's a SSL issue? It would be great to get more information about the reason for the failing (e.g. in the http response or directly in the ui). Also the log files within the container doesn't contain something helpful.

My start command:

docker run -d \
  -p 8080:80 \
  -e REGISTRY_HOST=registry.domain.net \
  -e REGISTRY_PORT=80 \
  -e REGISTRY_PROTO=https \
  -e REGISTRY_SSL_VERIFY=true \
  -e REGISTRY_USERNAME=user \
  -e REGISTRY_PASSWORD=pw \
  -e REGISTRY_ALLOW_DELETE=false \
  --name ui \
  parabuzzle/craneoperator:latest

Looking forward to your response! Cheers Philipp

parabuzzle commented 8 years ago

@phauer I'll look into it.

A few questions (and possible solutions)...

Does your registry really run on port 80 with ssl? if its on port 80 without SSL, you may want to set REGISTRY_PROTO=http instead...

If your registry is using ssl you probably want to set REGISTRY_PORT=443

If it's running self signed certificates.. you will want to set REGISTRY_SSL_VERIFY=false

phauer commented 8 years ago

Hi parabuzzle, thanks for your fast response. You're absolutely right, it should be REGISTRY_PORT=443. However, I get exactly the same error. It's not a self signed certificate, but setting REGISTRY_SSL_VERIFY=false didn't helped either.

Strange. But I can call the registry without any problems:

$ http --auth user:pw https://registry.domain.net:443/v2/_catalog
parabuzzle commented 7 years ago

@phauer I just figured this out today. I a fix is on the way. sorry for the delay here

parabuzzle commented 7 years ago

crap. I just realized I fixed this in my Company's fork of this repo but never fixed it here.. I'll get that out this week.