We recently released the latest version (5.0.1) of Rubrik’s most popular SDK, the Rubrik SDK for PowerShell. The module allows you to interact with your Rubrik Clusters and automate tasks such as assigning SLAs, taking snapshots, and pausing backups to allow for patching or to generate customized reports retrieved from the Rubrik Cluster.
About the Module
The PowerShell module was originally created in 2015 and has been widely adopted with over 9,000 downloads. Last summer, we began formulating a strategy to make the module more maintainable and accessible, which we dubbed “Project Quokka.” This included migrating the module to Azure DevOps for CI, creating unit tests that allow for simplified validation if future changes in the code are breaking existing functionality, and providing updated and complete documentation for all private and public functions in the module.
One of the project’s first initiatives was to update the module to be compatible with PowerShell Core, allowing it to be used on macOS and Linux, as well as Windows.
Over a thousand codebase changes were made in our latest release, with some great contributions made by community members such as Nick Shores who provided a number of functions to help with bootstrapping a Rubrik Cluster. Here are some of the biggest additions to the PowerShell module:
Added default display properties to improve output
In previous releases of the module, there were no default output types defined, which can be a bit overwhelming, as it might not be relevant to view all the properties of each VM. PowerShell’s default output types only allow for several properties of each object to display. The effect of using default output types in the module is that it becomes more straightforward to interactively work with the module.
The result of this is as follows:
It’s important to note that this is only a change to how the output is displayed by default and does not impact scripts or automations that rely on properties to be present. If you would still like to view all the properties, simply run the following command:
Since this is new functionality, we are actively looking for feedback on which properties should be displayed. If you have any thoughts, don’t hesitate to raise an issue on GitHub.
vCloud Director Support
To be able to better support VMware’s deployment & automation software, we have created new cmdlets that provide this functionality. For example, it is now possible to verify the protection state of vApps and manage the vApps:
My colleague, Matt Elliott, wrote a blog post outlining the vCloud Director cmdlets in more detail.
New Rubrik SLA functionality
The Rubrik SLA cmdlets allow us to not only configure new settings, but also modify settings on existing SLAs. In the following example, I am modifying the frequency and retention policies in the “TestSLA” domain:
Future releases of the Rubrik module will be published on the PowerShell Gallery with 5.0.x version increments. This means that updates are pushed on a more regular basis and will give us additional time to perform integration and unit tests. Future releases will have documentation to provide additional information about what is new in this function.
We will continue to take feedback in the form of enhancement requests and bug reports through GitHub. If you have any questions or concerns, feel free to raise an issue on the Rubrik SDK for PowerShell repository.
Whether you have used the PowerShell module in the past or not, the latest version is the most stable and feature packed SDK we have released at Rubrik. Take a look at what we’ve built so far: PowerShell Gallery – Rubrik.