-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
EC2 Linux slave, job definition with cridentials different from defined in jenkens configuration
Hi.
I am using ssh-agent plugin to define cridentials for my job(node is defined with user "ec2-user" but I want to run build script under different user - ctmacc1)
I have defined such user on EC2 linux node , with same ssh key as ec2-user. When I connect to machine manually (putty) with ctmacc1 - it works with no problem
But when I run job through jenkins - I see following:
________________________________________________________
[ssh-agent] Looking for ssh-agent implementation...
[ssh-agent] Java/JNR ssh-agent
[ssh-agent] Registered BouncyCastle on the remote agent
[ssh-agent] Started.
[ssh-agent] Using credentials ctmacc1
[RH12CtmAws] $ /bin/sh -xe /tmp/hudson1327337313392147816.sh
+ id
uid=1000(ec2-user) gid=1000(ec2-user) groups=1000(ec2-user),4(adm),10(wheel),190(systemd-journal) context=unconfined_u:unconfined_r:unconfined_t:s0
________________________________________________________
That means ssh-agent says that it uses cridentials ctmacc1 at which user name is defigned to be
ctmacc1. But "id" command at build script shows that it actually runs under ec2-user