use of io.fabric8.maven.docker.util.VolumeBindingUtil.resolveRelativeVolumeBindings in project docker-maven-plugin by fabric8io.
the class DockerComposeServiceWrapper method getVolumeConfig.
RunVolumeConfiguration getVolumeConfig() {
RunVolumeConfiguration.Builder builder = new RunVolumeConfiguration.Builder();
List<String> volumes = asList("volumes");
boolean added = false;
if (volumes.size() > 0) {
builder.bind(volumes);
added = true;
}
List<String> volumesFrom = asList("volumes_from");
if (volumesFrom.size() > 0) {
builder.from(volumesFrom);
added = true;
}
if (added) {
RunVolumeConfiguration configuration = builder.build();
VolumeBindingUtil.resolveRelativeVolumeBindings(baseDir, configuration);
return configuration;
}
return null;
}
Aggregations