0

i was able to run successfully local Eclipse Ditto version using docker container latest version downloaded from https://github.com/eclipse/ditto/tree/master/deployment/docker. Following the tutorial I was training first to create a new policy using the following curl:

curl -X PUT 'http://localhost:8080/api/2/policies/my.test:policy' -u 'ditto:ditto' -H 'Content-Type: application/json' -d '{
    "entries": {
        "owner": {
            "subjects": {
                "nginx:ditto": {
                    "type": "nginx basic auth user"
                }
            },
            "resources": {
                "thing:/": {
                    "grant": [
                        "READ","WRITE"
                    ],
                    "revoke": []
                },
                "policy:/": {
                    "grant": [
                        "READ","WRITE"
                    ],
                    "revoke": []
                },
                "message:/": {
                    "grant": [
                        "READ","WRITE"
                    ],
                    "revoke": []
                }
            }
        }
    }
}'

401 - Authentication is possible but has failed or not yet been provided, the same one I'm getting from the local swagger. Trying to create it on sandbox: https://www.eclipse.org/ditto/http-api-doc.html#/ I'm getting: Undocumented TypeError: NetworkError when attempting to fetch resource.

What I'm missing? i choose the API version 2 and authorize myself as a ditto user to start working. Is there any additional configuration required to start working with the local version? And what I'm doing wrong with the sandbox?

  • Did you modify anything in the docker-compose.yaml? That should work out of the box. The sandbox is currently not running and is not always available, that explains the error there. – Thomas Jäckle Dec 09 '21 at 08:23
  • no, i didn't. Just to be 100% sure, now I refreshed all files like yaml and config from the git and restarted the docker container. But I can see the same issue. Moreover, opening the swagger and clicking on the Things POST option I'm getting this error: Resolver error at paths./things.post.responses.413.$ref Could not resolve reference: Could not resolve pointer: /components/responses/entityTooLarge does not exist in document. – Liudmila Dobriakova Dec 10 '21 at 12:58

0 Answers0