List of usage examples for org.springframework.ide.eclipse.boot.dash.cloudfoundry.deployment CloudApplicationDeploymentProperties getEnvironmentVariables
public Map<String, String> getEnvironmentVariables()
From source file:org.springframework.ide.eclipse.boot.dash.cloudfoundry.CloudAppDashElement.java
public void push(CloudApplicationDeploymentProperties deploymentProperties, RunState runningOrDebugging, DebugSupport debugSupport, CancelationToken cancelationToken, UserInteractions ui, IProgressMonitor monitor) throws Exception { boolean isDebugging = runningOrDebugging == RunState.DEBUGGING; whileStarting(ui, cancelationToken, monitor, () -> { // Refresh app data and check that the application (still) exists in // Cloud Foundry // This also ensures that the 'diff change dialog' will pick up on // the latest changes. // TODO: should this refresh be moved closer to the where we // actually compute the diff? CloudAppDashElement updatedApp = this.refresh(); if (updatedApp == null) { ExceptionUtil.coreException(new Status(IStatus.ERROR, BootDashActivator.PLUGIN_ID, "No Cloud Application found for '" + getName() + "'")); }/*from w w w .j a v a 2s. c om*/ IProject project = getProject(); if (project == null) { ExceptionUtil.coreException(new Status(IStatus.ERROR, BootDashActivator.PLUGIN_ID, "Local project not associated to CF app '" + getName() + "'")); } checkTerminationRequested(cancelationToken, monitor); CloudApplicationDeploymentProperties properties = deploymentProperties == null ? getCloudModel().resolveDeploymentProperties(updatedApp, ui, monitor) : deploymentProperties; // Update JAVA_OPTS env variable with Remote DevTools Client secret DevtoolsUtil.setupEnvVarsForRemoteClient(properties.getEnvironmentVariables(), DevtoolsUtil.getSecret(project)); if (debugSupport != null) { if (isDebugging) { debugSupport.setupEnvVars(properties.getEnvironmentVariables()); } else { debugSupport.clearEnvVars(properties.getEnvironmentVariables()); } } checkTerminationRequested(cancelationToken, monitor); CFPushArguments pushArgs = properties.toPushArguments(getCloudModel().getCloudDomains(monitor)); getClient().push(pushArgs, CancelationTokens.merge(cancelationToken, monitor)); log("Application pushed to Cloud Foundry: " + getName()); }); }