-
Notifications
You must be signed in to change notification settings - Fork 46
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
[feature request] Add a new score-compose provisioners list
command
#237
Comments
Can I rather recommend we use |
Fo |
score-compose resources available-provisioners
commandscore-compose provisioners list
command
@mathieu-benoit I could give it a try |
That would be awesome! If you have any questions while implementing this, please do let us know. There is a #score-dev channel in the CNCF Slack for this purpose. |
Have a question related to array to display, currently after running From this file I can easily extract type and output, I see that params will need a little more work but nothing reallay hard. Finally it is for the class header I am not sure where it is defined and I did not found any documentation that describe this field. Could you give me some guidance here ? |
Good question, it's not yet well documented for this part, I'll add a note to this one score-spec/docs#121 to make sure we'll document this properly. In the meantime, here is the tl,dr about
Hope this helps for more context? |
Think I got it so basically if the field class is not specified I can assume it is |
@lekaf974 @mathieu-benoit actually a small clarrification! If the provisioner doesn't specify a class, it will match ALL classes. Same with the So a provisioner for type: postgres, class: "", will still be able to provision a resource with type: postgres, class: advanced. |
Thanks for the clarification, @astromechza. But just to make sure about that:
So |
Thanks you for feedback to you. Having a look deeper in the code, did not found existing code that I can reuse or I missed something @astromechza could you give an advice ? My first idea is to loop on all Z-xx.xxx.providers.yaml files in |
What about Used here as an example: https://github.com/score-spec/score-compose/blob/main/internal/command/generate.go#L216 |
Tried this way but it returns this interface which does not expose the required information score-compose/internal/provisioners/core.go Line 100 in ab1f356
From what I have seen looks this struct contains the required data
|
@lekaf974 modify the interface to expose the type, class, id as well. @mathieu-benoit no the class should be displayed as "*" or "any" rather than "default" if it is blank or not specified. |
Gotcha, makes sense with |
thanks will update interface |
Add a new
score-compose provisioners list
command generating in the output this table or a more advanced/detailed version with-o json
: https://docs.score.dev/docs/score-implementation/score-compose/resources-provisioners/.score-go
as it's specific to each implementation.provisioners
imported via thescore-compose init --provisioners
commandThe text was updated successfully, but these errors were encountered: