Skip to content

Commit

Permalink
implemented feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter Bollen authored and rnorth committed Feb 12, 2017
1 parent c2c6576 commit 9cefeb7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,11 @@ public String getStderr() {
/**
* Adds container volumes.
*
* @param otherContainer the other container object to add volumes from
* @param container the container to add volumes from
* @param mode the bind mode
* @return this
*/
SELF withVolumesFrom(String otherContainer, BindMode mode);
SELF withVolumesFrom(Container container, BindMode mode);

/**
* Set the ports that this container listens on
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -505,13 +505,13 @@ public SELF withFileSystemBind(String hostPath, String containerPath, BindMode m
* {@inheritDoc}
*/
@Override
public SELF withVolumesFrom(String otherContainer, BindMode mode) {
addVolumesFrom(otherContainer, mode);
public SELF withVolumesFrom(Container container, BindMode mode) {
addVolumesFrom(container, mode);
return self();
}

private void addVolumesFrom(String otherContainer, BindMode mode) {
volumesFroms.add(new VolumesFrom(otherContainer, mode.accessMode));
private void addVolumesFrom(Container container, BindMode mode) {
volumesFroms.add(new VolumesFrom(container.getContainerName(), mode.accessMode));
}

@Override
Expand Down

0 comments on commit 9cefeb7

Please sign in to comment.