-
Notifications
You must be signed in to change notification settings - Fork 74
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(providers) initial implementation of pulumi provider #180
Conversation
1c343aa
to
4dec338
Compare
4dec338
to
989c698
Compare
d7438ae
to
56a8a19
Compare
@agershman please fix ci issues. |
56a8a19
to
ab55949
Compare
@yxxhero should be good to go now. Thanks |
} | ||
|
||
func (p *provider) GetString(key string) (string, error) { | ||
tokens := strings.Split(key, "/") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@agershman we should check the length of tokens here. WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, I think that'd be helpful to be more explicit if the provided key is not in a supported format. Will address.
pkg/providers/pulumi/pulumi.go
Outdated
case "pulumistateapi": | ||
state, err = p.getStateFromPulumiAPI() | ||
default: | ||
return "", fmt.Errorf("unsupported backend: %s", p.backend) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
err = fmt.Errorf("unsupported backend: %s", p.backend)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will address.
ab55949
to
9f93a65
Compare
Signed-off-by: Andrew Gershman <[email protected]>
9f93a65
to
e9f10eb
Compare
This is an initial implementation of a Pulumi provider backed by state. This first cut meets my use case of obtaining state from the Pulumi REST API. I've updated the readme with the relevant usage and a couple examples.