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

feat(provider/cf): add provider skeleton with credentials management #2838

Merged
merged 2 commits into from Aug 14, 2018

Conversation

jkschneider
Copy link
Member

Based on a conversation with @duftler, we're splitting up the Cloud Foundry provider submission into individual PRs that can be reviewed in smaller chunks.

This initial PR contains the skeleton of the provider, up to and including credentials.

cloudfoundry:
  enabled: true
  accounts:
    - name: pivotalwebservices
      user: MYUSER
      password: MYPASSWORD
      api: api.run.pivotal.io

cc / @ethanfrogers

@spinnakerbot
Copy link
Contributor

The following commits need their title changed:

e833e31: feat(provider/cf) add provider skeleton with credentials management

Please format your commit title into the form:

<type>(<scope>): <subject>, e.g. fix(kubernetes): address NPE in status check

This allows us to easily generate changelogs & determine semantic version numbers when cutting releases. You can read more about commit conventions here.

@jkschneider jkschneider changed the title feat(provider/cf) add provider skeleton with credentials management feat(provider/cf): add provider skeleton with credentials management Aug 6, 2018
Copy link
Member

@lwander lwander left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

*/

package com.netflix.spinnaker.clouddriver.cloudfoundry

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We try to write all new code in Java/Kotlin -- take for example the new k8s provider in clouddriver

It's not exactly a hard requirement, but would be nice

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh boy. I wish we had known this before we wrote the whole provider.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are some notes on the site here (https://www.spinnaker.io/community/contributing/back-end-code/), but we could definitely do a better job of publicizing this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Frankly, we could probably put a little bit in the parent build to disallow it from even happening for new providers. But I suppose new providers don't come along every day.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We were thinking of adding it as a spinbot check.


@Override
Collection<Agent> getAgents() {
agents
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We try to avoid eliding return


@Override
String getAgentType() {
"${accountName}/${this.class.simpleName}"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same return comment here

@jkschneider
Copy link
Member Author

@lwander @duftler converted to Java.

Copy link
Member

@lwander lwander left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, sorry about the trouble

@lwander lwander merged commit 1f48dc3 into spinnaker:master Aug 14, 2018
@duftler
Copy link

duftler commented Aug 14, 2018

Nice!

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