Atomist software delivery machine (SDM) extension pack for an Atomist SDM to deploy to Cloud Foundry. These capabilities will work for both open source and Pivotal Cloud Foundry.
See the Atomist documentation for more information on what SDMs are and what they can do for you using the Atomist API for software.
Install the dependency in your SDM project.
$ npm install @atomist/sdm-pack-cloudfoundry
Then use its exported method to add the functionality to your SDM in your machine definition.
import {
SoftwareDeliveryMachine,
SoftwareDeliveryMachineConfiguration,
} from "@atomist/sdm";
import {
createSoftwareDeliveryMachine,
} from "@atomist/sdm-core";
import {
CloudFoundrySupport,
} from "@atomist/sdm-pack-cloudfoundry";
export function machine(configuration: SoftwareDeliveryMachineConfiguration): SoftwareDeliveryMachine {
const sdm = createSoftwareDeliveryMachine({
name: "My Software Delivery Machine",
configuration,
});
sdm.addExtensionPacks(SeedSupport);
sdm.addDeployRules(
deploy.when(IsMaven)
.deployTo(ProductionDeploymentGoal, ProductionEndpointGoal, ProductionUndeploymentGoal)
.using({
deployer: new CloudFoundryBlueGreenDeployer(configuration.sdm.projectLoader),
targeter: () => new EnvironmentCloudFoundryTarget("production"),
}),
);
return sdm;
};
Finally, add the required configuration values to your client configuration.
{
"sdm": {
"cloudfoundry": {
"user": "[email protected]",
"password": "cFpAsSw0rD",
"org": "cf-organiation",
"spaces": {
"staging": "cf-staging-space",
"production": "cf-production-space"
}
}
}
}
General support questions should be discussed in the #support
channel in the Atomist community Slack workspace.
If you find a problem, please create an issue.
You will need to install Node.js to build and test this project.
Install dependencies.
$ npm install
Use the build
package script to compile, test, lint, and build the
documentation.
$ npm run build
Releases are handled via the Atomist SDM. Just press the 'Approve' button in the Atomist dashboard or Slack.
Created by Atomist. Need Help? Join our Slack workspace.