Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
546 views
in Technique[技术] by (71.8m points)

google cloud platform - connecting jenkins gcp slave agent using gce plugin failing with ssh timeout

created service account and provided required permissions as below

Hi ,

I'm trying to run a jenkins job using gcp agents by using gce plugin.Created service account as below and provied required privileges

gcloud iam service-accounts create jenkins

export PROJECT=$(gcloud info --format='value(config.project)') 
export SA_EMAIL=$(gcloud iam service-accounts list --filter="name:jenkins" 
 --format='value(email)') 
gcloud projects add-iam-policy-binding --member serviceAccount:$SA_EMAIL 
 --role roles/compute.instanceAdmin $PROJECT
gcloud projects add-iam-policy-binding --member serviceAccount:$SA_EMAIL 
 --role roles/compute.networkAdmin $PROJECT
gcloud projects add-iam-policy-binding --member serviceAccount:$SA_EMAIL 
 --role roles/iam.serviceAccountUser $PROJECT
 gcloud projects get-iam-policy $PROJECT

created key for service account and downloaded the same and created credential in jenkins master as jp-practice

Used the same in below configuration

enter image description here

But when i trigger job it is throwing below ssh connect error

enter image description here

Could you please help to identify the issue

question from:https://stackoverflow.com/questions/65517177/connecting-jenkins-gcp-slave-agent-using-gce-plugin-failing-with-ssh-timeout

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...