Pivotal Knowledge Base

Follow

Have to log in manually if refresh token expires when deploy app to PWS via CloudBees Jenkins Platform

Symptoms
CloudBees Jenkins Platform provides an integrated feature which helps to deploy apps to Cloud Foundry/PWS. The component logs into Cloud Foundry with a token instead of username/password.  When the access token expires, the plugin is able to update the access token by using the refresh token.  However, in the token refresh expires, CloudBees Platform requires you to manually enter username/password which break the continuous deployment. 

Resolution

The CloudBees Platform plugin — Cloud Foundry Plugin, helps to eliminate above problem via login to Cloud Foundry/PWS with username/password each time instead of a token. Here are the steps to install and configure the plugin: 

- Install Cloud Foundry Plugin
Move to "Jenkins | Manage Jenkins | Manage Plugins", select "Available" tab, search "Cloud Foundry Plugin" in Filter box. Once find it, select checkbox and click "Install without restart". 
 
- Configure Jenkins project with the plugin
Select a Jenkins project, click "Configure", at "Post-build Actions" section, click "Add post-build action" pull-down menu, select "Push to Cloud Foundry".  Fill in PWS api endpoint, credentials, organization, space, etc. Click "Save" to complete the setup. 

Comments

Powered by Zendesk