< Back

Set-AMProcess

Sat Jan 11, 2020 3:31 am

NAME Set-AMProcess



SYNOPSIS

Sets properties of an AutoMate Enterprise process.





SYNTAX

Set-AMProcess -InputObject <Object> [-Notes <String>] [-CommandLine <String>] [-WorkingDirectory <String>]

[-EnvironmentVariables <String>] [-RunningContext {Default | SH | Bash}] [-CompletionState {InDevelopment |

Testing | Production | Archive}] [-WhatIf] [-Confirm] [<CommonParameters>]



Set-AMProcess -Instance <Object> [-WhatIf] [-Confirm] [<CommonParameters>]





DESCRIPTION

Set-AMProcess can change properties of a process object.





PARAMETERS

-InputObject <Object>

The object to modify.



Required? true

Position? named

Default value

Accept pipeline input? true (ByValue)

Accept wildcard characters? false



-Instance <Object>

The process object to save directly to the server. This parameter takes a process that has been manually

modified to be saved as-is to the server.



Required? true

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Notes <String>

The new notes to set on the object.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-CommandLine <String>

The command to run.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-WorkingDirectory <String>

The working directory to use when running the command.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-EnvironmentVariables <String>

Environment variables to load when running the command.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-RunningContext

The context to execute the command in: Default, SH or Bash.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-CompletionState

The completion state (staging level) to set on the object.



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Confirm [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

The following AutoMate object types can be modified by this function:

Process





OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\># Change command for a process



Get-AMProcess "Start Service" | Set-AMProcess -Notes "Starts a service"









-------------------------- EXAMPLE 2 --------------------------



PS C:\\># Empty notes for all agent groups



Get-AMProcess | Set-AMProcess -RunningContext Bash











RELATED LINKS

https://github.com/AutomatePS/AutomatePS