본문 바로가기
기술스택을 쌓아보자/에러 로그 수집기

[docker] Error saving credentials: error storing credentials - err: exec: "docker-credential-desktop.exe": executable file not found in $PATH, out: ``

by 소리331 2024. 3. 13.
반응형

azure cloud registry에 접속하기 위해서 docker login을 셋팅하려고 하는데, 제목과 같은 에러가 나타났다. 

 

$ az acr login -n my-registry

Error saving credentials: error storing credentials - err: exec: "docker-credential-desktop.exe":
executable file not found in $PATH, out: ``                                                                                                   
Login failed.

 

알고 보니 docker의 credential 정보를 저장하는 경로의 매핑이 잘못되어 있어 생긴 문제이다. 

home 경로로 이동하여 `.docker/config.json` 에서 credsStore부분을 지워주니 해결되었다.

 

{
  "auths": {
    "finterhub.azurecr.io": {},
    "https://index.docker.io/v1/": {}
  },
  "credHelpers": {
    "asia.gcr.io": "gcloud",
    "eu.gcr.io": "gcloud",
    "gcr.io": "gcloud",
    "marketplace.gcr.io": "gcloud",
    "staging-k8s.gcr.io": "gcloud",
    "us.gcr.io": "gcloud"
  },
  "credsStore": "desktop.exe" => 이부분을 삭제해준다!
}

 

이후 재실행하니 성공!

$ az acr login -n my-registry             
Login Succeeded

 

반응형

댓글