Ensure Server
- 14 May 2021
- 1 Minute to read
- Print
- DarkLight
- PDF
Ensure Server
- Updated on 14 May 2021
- 1 Minute to read
- Print
- DarkLight
- PDF
Article Summary
Share feedback
Thanks for sharing your feedback!
This is generated from the built in components of Otter 3.0.0, and may be different than what you have installed (especially if you have extensions); go to [User Icon] -> Documentation within your BuildMaster instance to see exactly what operations are available.
Ensure Server
Ensures that a server exists within Otter.
Script usage:
Ensure-Server( Name: <text>, [Exists: <true/false>], [Roles: <@(text)>], [Environments: <@(text)>], [RoutineExecutionType: <text>], [AgentConfigurationXml: <text>] );
This operation may be prefixed with Otter::
, although this is a built-in namespace and isn't really necessary.
Arguments:
Name | Format | Script Usage | Usage Notes |
---|---|---|---|
☆ Server name | text | Name | This argument is required. |
Exists | true/false | Exists | |
Server roles | @(text) | Roles | A collection of role names that the server belongs to. Any roles specified must already exist within Otter or a warning will be issued at execution time. |
Environments | @(text) | Environments | A collection of environment names that the server belongs to. Any environments specified must already exist within Otter or a warning will be issued at execution time. |
Drift remediation | text | RoutineExecutionType | The method that specifies the drift remediation. Valid values are E (automatically remediate), C (report only), or N (do not collect). The default value is report only. |
Agent configuration (XML) | text | AgentConfigurationXml | The serialized agent configuration that will be used by this server. |
Example:
# ensures that the specified server is present within Otter Ensure-Server( Name: HdarsWin12e-1A-dev, Roles: @(windows-east, development-1A, integration-1A), Environments: @(development), RoutineExecutionType: N # don't automatically detect drift for this server, AgentConfigurationXml: >><Inedo.Otter.Extensions.Agents.Tcp.TcpAgent Assembly="OtterCoreEx"> <Properties HostName="HdarsWin12e-1A-dev" Port="46336" SslRequired="False" /> </Inedo.Otter.Extensions.Agents.Tcp.TcpAgent>>> );
Was this article helpful?