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

Use explicitly a more recent jnlp-slave to avoid problems with cached… #631

Merged
merged 1 commit into from
Oct 31, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
import java.util.regex.Pattern;
import java.util.stream.Collectors;

import com.google.common.annotations.VisibleForTesting;
import io.fabric8.kubernetes.api.model.PodSpecFluent;
import org.apache.commons.lang.StringUtils;
import org.csanchez.jenkins.plugins.kubernetes.model.TemplateEnvVar;
Expand Down Expand Up @@ -93,8 +94,9 @@ public class PodTemplateBuilder {

private static final String WORKSPACE_VOLUME_NAME = "workspace-volume";

private static final String DEFAULT_JNLP_IMAGE = System
.getProperty(PodTemplateStepExecution.class.getName() + ".defaultImage", "jenkins/jnlp-slave:alpine");
@VisibleForTesting
static final String DEFAULT_JNLP_IMAGE = System
.getProperty(PodTemplateStepExecution.class.getName() + ".defaultImage", "jenkins/jnlp-slave:3.35-5-alpine");

private static final String JNLPMAC_REF = "\\$\\{computer.jnlpmac\\}";
private static final String NAME_REF = "\\$\\{computer.name\\}";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ private void validatePod(Pod pod, boolean fromYaml, boolean directConnection) {
assertEquals(2, containers.size());

assertEquals("busybox", containers.get("busybox").getImage());
assertEquals("jenkins/jnlp-slave:alpine", containers.get("jnlp").getImage());
assertEquals(DEFAULT_JNLP_IMAGE, containers.get("jnlp").getImage());

// check volumes and volume mounts
Map<String, Volume> volumes = pod.getSpec().getVolumes().stream()
Expand Down