Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jnlp connection? #437

Open
davorceman opened this issue Mar 25, 2024 · 0 comments
Open

jnlp connection? #437

davorceman opened this issue Mar 25, 2024 · 0 comments

Comments

@davorceman
Copy link

davorceman commented Mar 25, 2024

I have issue with some CI when running command via SSH. I found some suggestions that establishing jnlp kind of connection to the node may be a fix.

Not sure how to do that, because Launch agent by connecting it to controller is not available.

But maybe Launch agent via execution of command on the controller could be similar?

I can run some command like (found somewhere as a solution)

ssh -i /path/to/the/priv/key jenkins@<agent-ip> “curl -O https://<jenkins-url>/jnlpJars/agent.jar && java -jar agent.jar”

But idk how to dynamically get the agent IP.
I see in env that there are variables such as AGENT and AGENTJAR_URL, and I tried to set in “Launch command” field like this

ssh -i /path/to/the/priv/key jenkins@$AGENT “curl -O https://$AGENTJAR_URL/jnlpJars/agent.jar && java -jar agent.jar”

and this

ssh -i /path/to/the/priv/key jenkins@${AGENT} “curl -O https://${AGENTJAR_URL}/jnlpJars/agent.jar && java -jar agent.jar”

But that not helped

Does anyone know how to use Launch method Launch agent via execution of command on the controller?

Sry for typos and formatting, I’m writing this from my phone

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant