Skip to content

Invalid login credentials #71

@StWiemann

Description

@StWiemann

Hi, I was just trying to get this UI to run but I was having trouble with authentication.

I run a registry with Keycloak as Auth-Provider under docker.mydomain.com

I can easily log into that repository using docker login docker.mydomain.com providing my Keycloak-Credentials.

Now I configured Craneoperator to talk to my registry using the DNS:

      containers:
        - env:
            - name: REGISTRY_HOST
              value: docker.mydomain.com
            - name: REGISTRY_PORT
              value: '443'
            - name: REGISTRY_PROTOCOL
              value: https
            - name: ALLOW_REGISTRY_LOGIN
              value: 'true'
            - name: SESSION_SECRET
              value: RANDOM_STRING
            - name: REGISTRY_USERNAME
              value: SOME_USERNAME
            - name: REGISTRY_PASSWORD
              value: USER_PASSWORD
            - name: TITLE
              value: Super Registry UI
            - name: REGISTRY_ALLOW_DELETE
              value: 'true'

Crane starts and I get to the Frontpage saying "Error Loading Page - Registry requires authentication".
When I try to login I get "Invalid login credentials".

Logs from Craneoperator:

15:02:16 web.1 \| Error talking to the docker registry!
--
Fri, Jul 15 2022 5:02:16 pm | 15:02:16 web.1 \| - UNAUTHORIZED: authentication required
Fri, Jul 15 2022 5:02:16 pm | 15:02:16 web.1 \| 141.30.39.112 - - [15/Jul/2022:15:02:16 +0000] "GET /api/containers HTTP/1.1" 401 46 0.0171
Fri, Jul 15 2022 5:03:03 pm | 15:03:03 web.1 \| 141.30.39.112 - - [15/Jul/2022:15:03:03 +0000] "GET /login HTTP/1.1" 200 799 0.0023
Fri, Jul 15 2022 5:03:03 pm | 15:03:03 web.1 \| 141.30.39.112 - - [15/Jul/2022:15:03:03 +0000] "GET /api/registryinfo HTTP/1.1" 200 182 0.0013

Logs from Registry:


WARN[2775035] error authorizing context: authorization token required  go.version=go1.11.2 http.request.host=docker.mydomain.com http.request.id=3bbda34f-b058-408a-b7b2-c8a7f0d7be8c http.request.method=GET http.request.remoteaddr=SERVER_IP http.request.uri="/v2/_catalog?n=100&last=" http.request.useragent=
--
Fri, Jul 15 2022 5:02:16 pm | 10.42.5.92 - - [15/Jul/2022:15:02:16 +0000] "GET /v2/_catalog?n=100&last= HTTP/1.1" 401 145 "" ""

Does this not support the registry-login with OAuth? Even though I don't really know how the authentication mechanism behind the registry would effect this.

Thank you for any help.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions