GIT] repository 접속 및 clone 오류 (remote: HTTP Basic: Access denied. The provided password or token is incorrect ...)

·1 min read

[2023-11-10, 작성]

 

상황 설명) docker container Volume에 repository(gitlab)를 clone해서 작업하려고 한다.

VsCode > Clone Repository in Container Volume… > 아래 repository 링크 기입

https://gitlab.com/{company-name}/{repository-name}.git

 

에러 메시지)

remote: HTTP Basic: Access denied. The provided password or token is incorrect or your account has 2FA enabled and you must use a personal access token instead of a password. See https://gitlab.com/help/topics/git/troubleshooting_git#error-on-git-fetch-http-basic-access-denied 

fatal: Authentication failed for 'https://gitlab.com/{company-name}/{repository-name}.git/'

 

에러 메시지 해석 - 오류가 있다면, 댓글부탁드립니다. ^^)

repository에 접속하기 위한 계정 정보에 문제(불일치, 다른 계정 또는 계정 비밀번호 설정값이 다르다)로 이해했다.

 

해결방안)

접속링크에 계정id와 비밀번호를 명시해 사용한다.

기존 접속링크 : https://gitlab.com/{company-name}/{repository-name}.git

해결방안 링크 : https://{계정id}:{비밀번호}@gitlab.com/{company-name}/{repository-name}.git