Installazione del modulo PowerShell

Migrate for Compute Engine consente di creare script di azioni da PowerShell utilizzando i comandi di un modulo personalizzato. Questo documento descrive l'installazione e l'utilizzo della guida integrata all'interno del modulo PowerShell.

Installazione dei moduli

  1. Scarica il programma di installazione del modulo PowerShell di Migrate for Compute Engine dalla pagina Download oppure apri il tuo Velostrata Manager e fai clic sull'icona di download dei moduli di PowerShell nella home page.
  2. Esegui il file di installazione e segui le istruzioni della procedura guidata. Devi accettare il Contratto di servizio con l'utente finale Velostrata e scegliere un percorso di installazione.

  3. Sono installati i seguenti moduli PowerShell:

    • Velostrata.PowerShell
    • Velostrata.Runbook
  4. Ora puoi connetterti a Velostrata Manager utilizzando:

PS C:\Users\Demo> Import-Module Velostrata.PowerShell
PS C:\Users\Demo> Connect-VelostrataManager

Lo script richiede l'IP di Velostrata Manager. Quando viene richiesto il nome utente, utilizza apiuser. La password è quella che imposti durante la creazione di Velostrata Manager.

Recupero della guida da PowerShell

Il modulo PowerShell fornisce assistenza tramite il comando Get-Help.

PS C:\Users\Demo> Get-help Connect-VelostrataManager

NAME
    Connect-VelostrataManager

SYNOPSIS
    This cmdlet establishes a connection to a Velostrata Manager Server
system.

    Connect-VelostrataManager [-Server] <String> [-Username] <String>
[-Password] <SecureString> [-Port [<Int32>]]

SYNTAX
    Connect-VelostrataManager [-Server] <String> [-Port <Int32>] [-Username]
<String> [-Password] <SecureString>  [<CommonParameters>]

DESCRIPTION
    The cmdlet starts a new session or re-establishes a previous session with
Velostrata Manager Server using the specified parameters.
    When you attempt to connect to a server, the server checks for valid
credentials and then sets the relevant PSVariables.
    Once the user is authenticated successfully, the session remains in effect
until the PowerShell session is closed or a new Velostrata Manager session is established.
    Note: You can have only one active connection to a Velostrata Manager server
per PowerShell local session.

REMARKS
    To see the examples, type: "get-help Connect-VelostrataManager -examples".
    For more information, type: "get-help Connect-VelostrataManager -detailed".
    For technical information, type: "get-help Connect-VelostrataManager -full".
    For online help, type: "get-help Connect-VelostrataManager -online"