public String getPort(String portType) {
    LocalConfiguration config = getConfiguration();
    config.applyPortOffset();

    if (!container.getState().isStarted()) {
      throw new IllegalStateException(
          "Container is not started, thus a port has not yet been assigned to the container.");
    }

    return config.getPropertyValue(portType);
  }
Get the basic port for the container

Calls {@link #getPort(String)} with the {@link ServletPropertySet#PORT} option.

@return the basic port for the container
geode-assembly/geode-assembly-test/src/main/java/org/apache/geode/session/tests/ServerContainer.java