### What happened in your environment? When executing command `oras repo ls localhost` I get this error: ``` Error: Get "http://localhost/v2/_catalog": dial tcp [::1]:80: connect: connection refused ``` There is no argument for using https, only for using http (`--plain-http`), so what's going wrong? ### What did you expect to happen? _No response_ ### How can we reproduce it? . ### What is the version of your ORAS CLI? Version: 1.1.0+Homebrew Go version: go1.21.0 ### What is your OS environment? MacOS ### Are you willing to submit PRs to fix it? - [ ] Yes, I am willing to fix it.
Activity
qweeah commentedon Sep 7, 2023
@erikschul Thanks for reporting this bug. Confirmed that
--plain-http=falsedoesn't work forlocalhostqweeah commentedon Sep 7, 2023
@erikschul There is a workaround, you may force the hostname to be not localhost like using
--resolve <mock-host>:443:0.0.0.0as below: