This repository contains a Jenkins Pipeline library for running CloudUnit tasks.
The documentation for the Jenkins Pipeline Shared Groovy Libraries Plugin contains all the details for importing and using a Pipeline library.
cloudunit(String host, String username, String password, String script)
host
contains the URL to connect to a CloudUnit Managerusername
CloudUnit userpassword
passwordscript
contains a CloudUnit CLI script
Connects to the CloudUnit Manager running at the specified URL, and runs the script, then disconnects.
Example:
def cloudunitHost = "http://cloudunit.dev"
cloudunit(cloudunitHost, "johndoe", "****", """
create-app --name ${env.BRANCH_NAME} --type tomcat-8
deploy --path target/ROOT.war
""")