내 terraform 모듈이 ssh 키를 통해 액세스되는 개인 bitbucket repo에 있습니다.Terraform이 git 용 ssh config를 준수하지 않음
terraform이 실행되는 git 명령이나 인증을 변경하는 방법을 모르지만 다른 ssh 구성을 사용하고있는 것으로 보입니다.
module "sdfsdfs" {
source = "git::ssh://bitbucket.org/mycomp/my-module-root//submodule"
}
임은 젠킨스 파이프 라인에서 이것을 실행하고 나는 특정 키를 사용하는 ssh를 설정을 편집하고 있습니다 :
이 내 TF 파일입니다. 나는이 작품을 입증했습니다 :
sshagent (credentials: ['my-ssh-key']) {
bat 'git clone [email protected]:mycomp/my-module.git'
}
ssh 구성이 올바르게 수정되고 jenkins에서 키 저장소를 사용합니다.
C:\Program Files\Git\cmd\git.exe exited with 128: Cloning into
'.terraform\modules\c760b746e09bd59ba86aae13dc9e9959'...
Permission denied (publickey).
fatal: Could not read from remote repository.
은 무엇인가 :
sshagent (credentials: ['my-ssh-key']) {
bat 'terraform init'
}
내가이 오류 :
나는 도대체 terraform 실제로 자식의 repo에서 끌어 실행되고 있지만이 ssh를 설정을 존중하지 모르겠어요 테라포밍은 여기서하고 있습니까? 또한 분명히이 세션에 대해서만이 설정을하고 싶기 때문에 제 젠킨스 서버에 대한 글로벌 ssh 설정을 할 수 없습니다.