Skip to content

When I execute an oras push, the scope that calls the get service token loses the push, only the pull #1599

@hopegi

Description

@hopegi

What happened in your environment?

  1. when i exec oras push xxx/xxx/test:v1 test.txt ,then i got a fail msg . but i add the --debug flag ,like oras push xxx/xxx/test:v1 test.txt --debug. it push successfully.
  2. this problem dose not apper in normal registry,like harbor,docker hub
  3. i catch access log find that when i exec cmd oras push xxx/xxx/test:v1 test.txt, the url of calling get service token like this https://127.0.0.1/service/token?service=hg-registry&scope=repository%3Ahg-ns1%2Ftest%3Apull and when i exec cmd oras push xxx/xxx/test:v1 test.txt --debug,the url is https://127.0.0.1/service/token?service=hg-registry&scope=repository%3Ahg-ns1%2Ftest%3Apush%2Cpull

there is something diff between within --debug and without --debug

What did you expect to happen?

No response

How can we reproduce it?

just exec the command and catch access log

What is the version of your ORAS CLI?

from 1.2.0 to latest 1.2.2 also has this problem

What is your OS environment?

every linux system

Are you willing to submit PRs to fix it?

  • Yes, I am willing to fix it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions