Teamcity does loop when using Command Line Build Steps

I want to use the Command Line Build Step and often used it successfully. But lately with two different usages I fail to use it. It keeps looping in the step without any error yield.

In the first example I use `git clone`:

`script { name = "Download Private BiKey" workingDir = "tools" scriptContent = """ mkdir private_key git clone git@github.com:xetra11/coopr-private-bikey.git /private_key """.trimIndent() }`

And in this state the build stays 4ever (already an hour now): https://imgur.com/8jkjXa1 

Another case is where I use SCP to download a file. It also just loops. When using commands the wrong way the build step fails as expected.


Can anybody tell me what that weird thing?

PS: I love Jetbrains but writing in this Support Forum is a real pain. You don't even have Code formatting. Jetbrains is all about code. Cmon guys!

PS2: Also there needs to be a PREVIEW button for posts. This is 2019 guys!

 

Greets

Charlie

0
3 comments

Hi Charlie, and thanks for your feedback. We'll see what we can do to improve the this platform.

 

Regarding your issue, you are trying to clone into "/private_key"? That looks like an absolute path into the root folder, which usually lacks permissions to do it. While I'm not exactly sure why the process doesn't error out, it would seem like that's incorrect unless the user running the script has root permissions, which is usually not a great idea. Further troubleshooting can be done following this steps: https://www.jetbrains.com/help/teamcity/common-problems.html#CommonProblems-BuildworkslocallybutfailsormisbehavesinTeamCity

Obviously you are already at the command line step of the troubleshooting steps, but you can log in into the agent, cd into the working directory and attempt running the steps there.

 

If the issue cannot replicate in that scenario, please collect some agent thread dumps while the agent is stuck and send them to us as the guide explains along with the build log and teamcity-agent.log.

0
Avatar
Permanently deleted user

I can confirm this - in my case TeamCity (we are using 2019.1.5) loops a complicated command build step and according to build log it just starts it again. There are no errors and first iteration completes successfully as there are no errors that should be processed - it is just a command line build step that runs different commands on agent.

I'll try to replicate and gather logs.

0

Hi Vladimir,

 

yes, please, replicate and pick up the requested logs. We use ourselves command line steps extensively and as you can imagine many of our users do, so there seems to be something very specific that would trigger that behavior. Might be even environmental. Does it replicate in every agent or only in some of them?

0

Please sign in to leave a comment.