Forum Discussion
Trying to replace the header host value if it doesn't match 2 conditions
You will have to do it programmatically in your code, i.e. get the list of all Virtual Servers first using get_list() call and store it in an array, then get the list of all destinations for all Virtual Servers using get_destination call with the array of all Virtual Servers as a parameter - you will now have two arrays - one with all the names, another one with all addresses, so just match the arrays.
Bear in mind that it is NOT a One-To-One relationship. One Virtual Address can belong to MANY Virtual Servers (for example you can have two Virtual Servers on the same IP, one for port 80 and another for port 443).
- May 14, 2013
Sorry about the deprecated methods. We do our best to make the methods both forward and backward compatible but the product does change and as underlying features change, the methods sometimes have to as well. In almost all cases, we've coded workarounds on the backend to make the "deprecated" methods still work with an urging to the user to migrate their code to the new methods.
As for folders, you'll have to look at how they work. Check out this tech tip I wrote a while back.
https://devcentral.f5.com/tech-tips...24-folders
It covers iApps and how they store them as well. If you want to get a list of all objects regardless of the "active" folder, you can use the recursive_query_state method in the System.Session interface.As for the cmdlets themselves, they were written to cover a few use cases but may not have been updated to fully support folders. You might want to do what you did by using the (Get-F5.iControl) pass through to get access to the core API methods. That's how I've modeled most of my samples on DevCentral.
-Joe
- Roostermiester_May 15, 2013
Nimbostratus
Thanks, using recursive_query_state method worked.
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com