Skip to content

fix: register CSP-format credential keys and return errors on failure in setup credential at mc-admin-cli - #220

Merged
MZC-CSC merged 2 commits into
m-cmp:mainfrom
MZC-CSC:develop
Oct 13, 2026
Merged

MZC-CSC merged 2 commits into
m-cmp:mainfrom
MZC-CSC:develop

Conversation

@MZC-CSC

@MZC-CSC MZC-CSC commented Oct 13, 2026

Copy link
Copy Markdown
Member

Changes

src/cmd/setup/credential.go

  • Take the input keys from CredentialCSP in the metainfo response
  • Return an error with the server message when the metainfo or credential registration response is not 2xx, and remove panic
  • Switch the credential command to RunE so it exits with code 1 on failure

yh-noh and others added 2 commits October 13, 2026 13:39
- 입력 키 목록을 metainfo의 Credential(cb-spider 형식) 대신 CredentialCSP에서 가져옴
  (예: AWS ClientId/ClientSecret -> aws_access_key_id/aws_secret_access_key)
  mc-infra-manager는 CSP 형식 키만 허용하여 기존에는 등록이 항상 거부됨
- sendCredentials가 HTTP 상태를 확인하여 2xx 외 응답을 오류로 반환, panic 제거
- metainfo 조회 실패(401 등)도 원인 메시지를 그대로 노출
- credential 명령을 RunE로 전환하여 실패 시 종료 코드 1 반환
  (기존에는 거부되어도 "Result: map[]" 출력 후 종료 코드 0)
fix: mc-admin-cli에서 setup credential 형식 보완
@MZC-CSC
MZC-CSC merged commit 604d5dc into m-cmp:main Oct 13, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants