Apache OpenWhisk is a serverless event-based programming service.
This plugin enables to manage OpenWhisk actions from a Gradle build script, without requiring to install anything on your system.
Add the following to build.gradle:
buildscript {
    repositories {
        maven { url 'https://jitpack.io' }
    }
    dependencies {
        classpath 'com.github.vic-cw:openwhisk-gradle-plugin:de1293'
    }
}
apply plugin: 'com.github.viccw.openwhisk-gradle-plugin'
task buildCloudFunctionZip (type: Zip) {
    // Logic to build artifact
    ...
}
updateDockerAction {
    artifactBuildTaskName = "buildCloudFunctionZip"
}
Set the following environment variables:
OPENWHISK_API_HOST: host of target OpenWhisk platform, for exampleeu-gb.functions.cloud.ibm.comOPENWHISK_AUTHORIZATION_KEY: key provided by OpenWhisk platformOPENWHISK_NAMESPACE: namespace of the action to update, for exampleyourcloudfoundryorg_yourcloudfoundryspaceOPENWHISK_ACTION_NAME: action nameOPENWHISK_WEB_SECURE_KEY: a 16 digit integer to secure access to OpenWhisk action
Use it:
// This updates the corresponding action on the target OpenWhisk platform
// with the output of the buildCloudFunctionZip task
./gradlew updateDockerAction
For more details see Full configuration options.
This plugin is still in its infancy and only supports a few features.
However, feel free to request a missing feature if you need it.