Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the ability to use the autopilot plugin for Cloud Foundry #328

Closed
jsloyer opened this issue Sep 4, 2015 · 9 comments
Closed

Add the ability to use the autopilot plugin for Cloud Foundry #328

jsloyer opened this issue Sep 4, 2015 · 9 comments

Comments

@jsloyer
Copy link

jsloyer commented Sep 4, 2015

Currently the Cloud Foundry command line allows the use of plugins to do additional things with deployments. A particular plugin AutoPilot allows the user to perform Blue/Green deployments for ensuring there is no downtime for their apps.

This issue is to get the idea on the books. I am offering to do the work for this but just wanted to bring the idea up to the community.

@jsloyer
Copy link
Author

jsloyer commented Sep 4, 2015

I would like to suggest the way to do this is adding the config to .travis.yml. The usage of this plug is below.

go get github.com/concourse/autopilot
cf install-plugin $GOPATH/bin/autopilot
cf login -a ${CF_API} -u ${CF_USERNAME} -p ${CF_PASSWORD} -o ${CF_ORG} -s ${CF_SPACE}
cf zero-downtime-push myapp -f manifest.yml

Proposed syntax below.

  plugin:
    url: github.com/concourse/autopilot
    installCommand: $GOPATH/bin/autopilot
    command: zero-downtime-push

Full .travis.yml file with proposed syntax.

language: node_js
node_js:
- '0.12'
sudo: required
deploy:
  edge: true
  provider: cloudfoundry
  api: xxxx
  username: xxxxx
  manifest: manifest.yml
  password: xxxx
  organization: xxxx
  space: xxxx
  plugin:
    url: github.com/concourse/autopilot
    installCommand: $GOPATH/bin/autopilot
    command: zero-downtime-push

@jimlindeman
Copy link

So is the trade-off here is that the coordination of the blue-green app-swap (route-management and app scaling commands to CF) is driven by the CF command-line tool? I assume the issuer of this command have to maintain network connectivity while the update is going on in the background (which can be a problem for long running "version A vs. version B" tests).

@jsloyer
Copy link
Author

jsloyer commented Sep 11, 2015

@jimlindeman I guess Im pissing your point, is your comment a statement?

@jsloyer
Copy link
Author

jsloyer commented Sep 11, 2015

Closing... No need for this, the correct way looks like scripts. For example a script that does this, https://github.com/18F/cf-blue-green.

@jsloyer jsloyer closed this as completed Sep 11, 2015
@afeld
Copy link

afeld commented Jun 8, 2016

As the author of that aforementioned script, I recommend using autopilot instead 😄 They do largely the same thing, but autopilot enforces some better habits, and is better maintained.

Would there be any interest in supporting autopilot as an option for the Cloud Foundry deploy? I think it would be fairly straightforward to add support...would you consider a pull request?

@afeld
Copy link

afeld commented Jun 22, 2016

Bump!

@rafael-nogueras
Copy link

@afeld I think integration of Autopilot with the CloudFoundry Travis provider would be awesome, and exactly what I'm looking for! I hope they DO consider a pull request from you. :-D

@afeld
Copy link

afeld commented Sep 12, 2016

Looked into this a bit...it would require two additions to the configuration:

  • Specifying that you want to do zero-downtime deployment
  • Specifying the application name (autopilot can only deploy one application at a time)

The latter is a bit of a bummer, in that it would require a special setup for deploying multiple applications (e.g. a backend server and a frontend server)...probably(?) still worth including to cover the majority of cases.

@afeld
Copy link

afeld commented Apr 4, 2017

Submitted! #610

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants