/** * Returns the overlay configuration for the given list of profile ids and the configuration PID. * * This method will find the overlay profile for each profile id and combine all the configurations together. * * Usually we would use the Profile objects directly; but this API call is useful when creating new containers; letting us * figure out the effective overlay before a container exists. */ public static Map<String, String> getOverlayConfiguration(FabricService fabricService, Iterable<String> profileIds, String versionId, String pid) { String environment = fabricService.getEnvironment(); return getOverlayConfiguration(fabricService, profileIds, versionId, pid, environment); }
/** * Returns the overlay configuration for the given list of profile ids and the configuration PID. * * This method will find the overlay profile for each profile id and combine all the configurations together. * * Usually we would use the Profile objects directly; but this API call is useful when creating new containers; letting us * figure out the effective overlay before a container exists. */ public static Map<String, String> getOverlayConfiguration(FabricService fabricService, Iterable<String> profileIds, String versionId, String pid) { String environment = fabricService.getEnvironment(); return getOverlayConfiguration(fabricService, profileIds, versionId, pid, environment); }
/** * Creates the environment variables for the given container options using the profiles specified in the options to figure out * what environment variables to use. */ public static Map<String, String> getEnvironmentVariables(FabricService service, CreateContainerOptions options) { return getEnvironmentVariables(service, options, service.getEnvironment()); }
protected Profile getProcessProfile(ProcessRequirements requirements, boolean includeController) { Container container = fabricService.getCurrentContainer(); ProcessProfile profile = new ProcessProfile(container, requirements, fabricService, includeController); return new ProfileOverlayImpl(profile, fabricService.getEnvironment(), true, fabricService); }
@Override public boolean isValidProvider() { // child provider isn't valid in OpenShift environment FabricService service = getFabricService(); if (service != null) { // lets disable child if in docker or openshift environments String environment = service.getEnvironment(); if (Objects.equal(environment, "docker") || Objects.equal(environment, "openshift") || Objects.equal(environment, "kubernetes")) { return false; } } boolean openshiftFuseEnv = Strings.notEmpty(System.getenv("OPENSHIFT_FUSE_DIR")); boolean openshiftAmqEnv = Strings.notEmpty(System.getenv("OPENSHIFT_AMQ_DIR")); return !(openshiftFuseEnv || openshiftAmqEnv); }
public FabricDTO(FabricService fabricService) { this.zookeeperUrl = fabricService.getZookeeperUrl(); this.currentContainerName = fabricService.getCurrentContainerName(); this.defaultVersion = fabricService.getDefaultVersionId(); this.environment = fabricService.getEnvironment(); this.mavenRepoURI = asString(fabricService.getMavenRepoURI()); this.mavenRepoUploadURI = asString(fabricService.getMavenRepoUploadURI()); this.defaultJvmOptions = fabricService.getDefaultJvmOptions(); }
public FabricDTO(FabricService fabricService) { this.zookeeperUrl = fabricService.getZookeeperUrl(); this.currentContainerName = fabricService.getCurrentContainerName(); this.defaultVersion = fabricService.getDefaultVersionId(); this.environment = fabricService.getEnvironment(); this.mavenRepoURI = asString(fabricService.getMavenRepoURI()); this.mavenRepoUploadURI = asString(fabricService.getMavenRepoUploadURI()); this.defaultJvmOptions = fabricService.getDefaultJvmOptions(); }