2. Spring Cloud Skipper Integration

Skipper is a tool that allows you to discover Spring Boot applications and manage their lifecycle on multiple Cloud Platforms. You can use Skipper standalone or integrate it with Continuous Integration pipelines to help achieve Continuous Deployment of applications. For more details, review the reference guide for a complete overview and the feature capabilities.

Before we begin setting up Skipper to use with Spring Cloud Data Flow, let’s review the basics by understanding foundational design by which the relevant infrastructure is provisioned in Kubernetes. The tailormade three-minute-tour for Cloud Foundry walks through the fundamentals.

Next up, we will review the relevant artifacts to provision Spring Cloud Skipper in Cloud Foundry.

2.1 Download the Spring Cloud Skipper and Shell apps

wget http://repo.spring.io/snapshot/org/springframework/cloud/spring-cloud-skipper-server/1.0.0.BUILD-SNAPSHOT/spring-cloud-skipper-server-1.0.0.BUILD-SNAPSHOT.jar
wget http://repo.spring.io/snapshot/org/springframework/cloud/spring-cloud-skipper-shell/1.0.0.BUILD-SNAPSHOT/spring-cloud-skipper-shell-1.0.0.BUILD-SNAPSHOT.jar

2.2 Running the Skipper Server

Similar to SCDF-server, you can either deploy the skipper-server application on Cloud Foundry or on your local machine.

Let’s review the sample manifest.yml file to deploy the skipper-server application to Cloud Foundry.

---
applications:
- name: skipper-server
  host: skipper-server
  memory: 1G
  disk_quota: 1G
  instances: 1
  path: <PATH TO THE DOWNLOADED SKIPPER SERVER UBER-JAR>
env:
    SPRING_APPLICATION_NAME: skipper-server
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_URL: https://api.run.pivotal.io
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_ORG: {org}
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_SPACE: {space}
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_DOMAIN: cfapps.io
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_USERNAME: {email}
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_PASSWORD: {password}
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_DEPLOYMENT_SERVICES: rabbit
    SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_STREAM_ENABLE_RANDOM_APP_NAME_PREFIX: false

You need to fill in {org}, {space}, {email} and {password} before running these commands. Once you have the desired config values in the manifest.yml, you can run cf push command to provision the skipper-server.

[Warning]Warning

Only set 'Skip SSL Validation' to true if you’re running on a Cloud Foundry instance using self-signed certs (e.g. in development). Do not use for production.

[Note]Note

Skipper includes the concept of platforms, so it is important to define the "accounts" based on the project preferences. In the above YAML file, the accounts map to pws as the platform. This can be modified, and of course, you can have any number of platform definitions. More details are in Spring Cloud Skipper reference guide.