public static DoneablePod createDoneablePodDefaultImpl(PodConfiguration config) { DoneablePod doneablePod = config.getClient().pods() .createNew() .withNewMetadata() .withGenerateName(config.getContainerIdPrefix()) .addToLabels(config.getLabels())
.withNewMetadata() .withName("testpod") .addToLabels("server", "nginx")
private void launchPod(String appId, PodSpec podSpec, Map<String, String> labelMap, Map<String, String> idMap, Map<String, String> annotations) { client.pods() .createNew() .withNewMetadata() .withName(appId) .withLabels(labelMap) .withAnnotations(annotations) .addToLabels(idMap) .endMetadata() .withSpec(podSpec) .done(); }
.withNewMetadata() .withName(podTemplate.getName()) .addToLabels(labels)