- Community Home
- >
- Software
- >
- HPE Morpheus Software
- >
- HPE Morpheus Enterprise
- >
- Re: Workflow Phase Detection
Categories
Company
Local Language
Forums
Discussions
Knowledge Base
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2024 10:18 AM
04-11-2024 10:18 AM
Hello All,
As you can see by the Subject line I’m wondering if there is a way to detect which phase its currently being ran. The reason being I’m working on a script for my job that has to be ran on Post-Provision but also Teardown . At the moment its two scripts but I would like to have it so it’s a single script. I tried searching around the Doc’s and did not see a whole lot unless i missed something. Any help would be apricated.
Solved! Go to Solution.
- Tags:
- powershell
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-12-2024 06:06 AM
04-12-2024 06:06 AM
Re: Workflow Phase Detection
@Tyler_Boyd Thank you! This helps a lot. I talked with my team and I think we’re just going to go with the two separate scripts. Thanks for the quick reply.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2024 08:19 PM
04-11-2024 08:19 PM
SolutionYou can use the <%= instance.status %> variable
During the Post-Provisioning phase it will be set to provisioning
During the Teardown phase it will be set to removing
One thing to keep in mind is if something where to fail during another phase (Ex. The Pre-Provision or Provision phase) this variable is set to “failed”. If you where to then retry the task it would not be set to the expected value.
For that reason I would probably keep it two separate tasks unless completely necessary.
Hope this helps ![]()