Skip to content

Conversation

@carolynvs
Copy link
Member

What does this change

Reads optional configuration from the porter configuration file and passes it to the plugin on stdin as json.

It is not sent as part of the plugin interface/contract because each plugin may or may not have config, it may look completely different or be loaded from other places, and I'd like to have the plugin contract mimic the cnab contracts. For example the interface for claims is the CrudStore.

default-instance-store = "porterci"

[[instance-store]]
  name = "porterci"
  plugin = "azure.blob"

  [instance-store.config]
    env = "PORTERCI_AZURE_STORAGE_CONNECTION_STRING"

What issue does it fix

N/A

Notes for the reviewer

This relies on a patch: hashicorp/go-plugin#127

This is the first step in getting a general framework in place for plugins. Next steps after this will be to make the pluginProvider generic so it can load a plugin and config for any interface. Right now I'm just feeling out what works.

@carolynvs
Copy link
Member Author

/azp run porter
/azp run porter-integration

@azure-pipelines
Copy link

No pipelines are associated with this pull request.

@carolynvs carolynvs marked this pull request as ready for review October 28, 2019 16:57
Copy link
Member

@vdice vdice left a comment

Choose a reason for hiding this comment

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

LGTM.

Should we add some sample porter configs to the docs? Or hold off, perhaps if more updates are planned?

@carolynvs
Copy link
Member Author

I was going to hold off until someone can install a plugin without having to compile it themselves.

@carolynvs carolynvs merged commit d5b7107 into getporter:master Oct 29, 2019
@carolynvs carolynvs deleted the claim-config branch October 29, 2019 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants