Here is an example YAML file to configure two Cloud Foundry accounts named cf-dev and cf-qa.
This is useful on Cloud Foundry if you are using the Spring Cloud Config Server to manage Skipper’s configuration properties.
Here is a sample YML snippet, modify to fit your needs.
![]() | Note |
|---|---|
It is important to set |
![]() | Note |
|---|---|
The |
spring:
cloud:
skipper:
server:
enableLocalPlatform: false
platform:
cloudfoundry:
accounts:
cf-dev:
connection:
url: https://api.run.pivotal.io
org: myOrg
space: mySpace
domain: cfapps.io
username: cf-dev@example.com
password: drowssap
skipSslValidation: false
deployment:
memory: 2048m
disk: 2048m
services: rabbit
deleteRoutes: false
cf-qa:
connection:
url: https://api.run.pivotal.io
org: myOrgQA
space: mySpaceQA
domain: cfapps.io
username: cf-qa@example.com
password: drowssap
skipSslValidation: true
deployment:
memory: 1024m
disk: 1024m
services: rabbitQA
deleteRoutes: falseYou can also run the Skipper Server locally and deploy to Cloud Foundry.
In this case, it is more convenient to specify the configuration in a skipper.yml file, and start the server with the option --spring.config.location=skipper.yml
If you are using cf push to deploy Skipper, a Cloud Foundry manifest is more appropriate to use.
Here is a sample manifest.yml, modify to fit your needs.
![]() | Note |
|---|---|
It is important to set |
![]() | Note |
|---|---|
It is important to set |
applications:
- name: mlp-skipper
host: mlp-skipper
memory: 1G
disk_quota: 1G
timeout: 180
instances: 1
buildpack: java_buildpack
path: spring-cloud-skipper-server.jar
env:
SPRING_APPLICATION_NAME: mlp-skipper
SPRING_CLOUD_SKIPPER_SERVER_ENABLE_LOCAL_PLATFORM: false
SPRING_CLOUD_SKIPPER_SERVER_STRATEGIES_HEALTHCHECK.TIMEOUTINMILLIS: 300000
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: myOrgQA
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_SPACE: mySpaceQA
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_DOMAIN: cfapps.io
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_USERNAME: cf-qa@example.com
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_PASSWORD: drowssap
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_CONNECTION_SKIP_SSL_VALIDATION: false
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_DEPLOYMENT_DELETE_ROUTES: false
SPRING_CLOUD_SKIPPER_SERVER_PLATFORM_CLOUDFOUNDRY_ACCOUNTS[pws]_DEPLOYMENT_SERVICES: rabbitmq
services:
- mysqlboost![]() | Note |
|---|---|
In the manifest above we bound the application to the |
For information on the deployment properties that can be configured can be found in CloudFoundryDeploymentProperties.
When starting the Skipper shell on your local machine, it will try to connect to the Server at the default location of localhost:7577/api.
Use the shell’s command line option --spring.cloud.skipper.client.serverUri to specify the location of the server.
You can alternatively use the interactive shell command config to set the server location
server-unknown:>skipper config --uri https://mlp-skipper.cfapps.io/api Successfully targeted https://mlp-skipper.cfapps.io/api skipper:>