I have a strange problem when running the tcl command in jenkins.
The tcl script has the following lines ( note the uppercase i in Id ):
foreach name $docker_names {
set name "TestName"
puts $name
set command "docker inspect --format='{{.Id}}' ${name} > /home/temp/id.txt"
send -- "$command\n"
expect "$"
}
In the jeknins log, I see that the job fails because the one sent in the second iteration of the loop is the command above, but in lower case. I need me to be uppercase in Id .
This is what is sent to the second iteration of the loop :
docker inspect --format='{{.id}}' testname > /home/temp/id.txt
NOTE. . At the first iteration, everything is sent correctly.
Does anyone have an idea why this is happening?
Thank!
source
share