Skip to content

meiswjn/docker-ssh-agent

 
 

Repository files navigation

Docker image for Jenkins agents connected over SSH

Join the chat at https://gitter.im/jenkinsci/docker GitHub stars Docker Pulls GitHub release

Warning! This image used to be published as jenkinsci/ssh-slave and jenkins/ssh-slave. These images are deprecated, use jenkins/ssh-agent.

A Jenkins agent image which allows using SSH to establish the connection. It can be used together with the SSH Build Agents plugin or other similar plugins.

See Jenkins Distributed builds for more info.

Running

To run a Docker container

docker run jenkins/ssh-agent "<public key>"

You'll then be able to connect this agent using the SSH Build Agents plugin as "jenkins" with the matching private key.

How to use this image with Docker Plugin

To use this image with Docker Plugin, you need to pass the public SSH key using environment variable JENKINS_AGENT_SSH_PUBKEY and not as a startup argument.

In Environment field of the Docker Template (advanced section), just add:

JENKINS_AGENT_SSH_PUBKEY=<YOUR PUBLIC SSH KEY HERE>

Don't put quotes around the public key. You should be all set.

Configurations

The image has several supported configurations, which can be accessed via the following tags:

  • latest: Latest version with the newest remoting (based on openjdk:8-jdk)
  • jdk11: Latest version with the newest remoting and Java 11 (based on openjdk:11-jdk)
  • alpine: Small image based on Alpine Linux (based on adoptopenjdk/openjdk8:jdk8u${version}-alpine)
  • jdk8-windowsservercore-1809: Latest version with the newest remoting (based on adoptopenjdk:8-jdk-hotspot-windowsservercore-1809)
  • jdk11-windowsservercore-1809: Latest version with the newest remoting and Java 11 (based on adoptopenjdk:11-jdk-hotspot-windowsservercore-1809)
  • jdk8-nanoserver-1809: Latest version with the newest remoting with Windows Nano Server
  • jdk11-nanoserver-1809: Latest version with the newest remoting with Windows Nano Server and Java 11

Changelog

See GitHub Releases. Note that the changelogs and release tags were introduced in Dec 2019, and there is no entries for previous patches. Please consult with the commit history if needed.

About

Docker image for Jenkins agents connected over SSH

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Dockerfile 44.8%
  • PowerShell 36.5%
  • Shell 16.3%
  • Makefile 2.4%