VMware Cloud Community
anoopvb
Enthusiast
Enthusiast
Jump to solution

How to store configuration information?

I'm building a few workflows that talk to several appliances.

I can prompt for the user/password as part of the workflow I think but I would like to store the following information somewhere so that i can easily reference it and pull it up for use rather than prompting the user.

I'm just looking to store

- hostname/ip

- username

- password

Where could i store that data?

The thought had occurred to create an Action to store it as a resource but I'm not sure if that's the right way to do it. I'm also not sure how to do it.

If someone has an example i can use, that would be greatly appreciated.

thank you.

1 Solution

Accepted Solutions
Hazenet
Enthusiast
Enthusiast
Jump to solution

Have a look at Step 5, of the blog post I referenced.

But short described, you create a Configuration Element, and manually populate that with your "configurations/settings".

When you create a Workflow that should use those "configurations/settings", you create a Attribute as you normally would, in the General tab of the Workflow.

But instead of manually giving your newly created Attribute a value, you link that Attribute to the Configuration Element Attribute.

When the Workflow is then run, the local Attribute is populated with what ever is in the linked Configuration Element Attribute.

View solution in original post

6 Replies
Hazenet
Enthusiast
Enthusiast
Jump to solution

anoopvb
Enthusiast
Enthusiast
Jump to solution

Is there a way to create this programmatically?


i.e. create a configuration item from running a workflow?


It seems like the configurations I create might be specific to me/my account?

When i look at the configurations tab, it's got my name @ IP on the top of the list.

Is there a way to make global configurations?

0 Kudos
anoopvb
Enthusiast
Enthusiast
Jump to solution

I've created a configurationElement but I'm not sure how to read that element with a script

Screen Shot 2016-09-02 at 3.50.26 PM.png

Would you happen to have an example of how I can read the ApplianceList element above?

0 Kudos
Hazenet
Enthusiast
Enthusiast
Jump to solution

Have a look at Step 5, of the blog post I referenced.

But short described, you create a Configuration Element, and manually populate that with your "configurations/settings".

When you create a Workflow that should use those "configurations/settings", you create a Attribute as you normally would, in the General tab of the Workflow.

But instead of manually giving your newly created Attribute a value, you link that Attribute to the Configuration Element Attribute.

When the Workflow is then run, the local Attribute is populated with what ever is in the linked Configuration Element Attribute.

anoopvb
Enthusiast
Enthusiast
Jump to solution

Ah got it! i used a scriptable task to read those and echo those into the system log.

Thank you. Can i ask one more question?

How do i add elements to an array of strings attribute in my element?

I'm reading something about categoryPath but i'm not sure what value that's supposed to have.

In this case, is it supposed to be "Anoop" as a string?

I'm effectively trying to push a new value into a array of strings.

thanks!

0 Kudos
-_DT_-
Contributor
Contributor
Jump to solution

hello there,

i'm looking for some help with drop down lists in a blueprint whereby i need the list to be populated by searchin a category, a file is selected in the category path based on the OS version of the blueprint, then those values are presented in a drop down list for a user to slecect and i just can't get there. i have used your tutorials, and others, but i'm lost. i can read and outout the file list in the category path but when trying to read the contents in said file then have them pushed back to the drop down is not working. any ideas or hints as to what i need to do?

 

 

thank you,

0 Kudos