Management Commands
Use these commands to set up the parameters of the On-Premises PCEs that you will be migrating.
Add PCE Parameters
Use this command to add an entry with specific parameters to the configuration YAML file for pcemigrate:
pce-add
% ~/pcemigrate/bin/pcemigrate pce-add --help Adds a PCE to the pce.yaml file. The default file name is pce.yaml stored in the current directory. Use the --config-file flag to set a custom file and use the --config-file on all subsequent commands. You can also use ILLUMIO_CONFIG environment variable. The command can be automated (avoid prompt) by using flags or the following following environment variables: PCE_NAME, PCE_FQDN, PCE_PORT, PCE_USER, PCE_PWD, PCE_DISABLE_TLS, PCE_PROXY, PCE_API_KEY, PCE_API_USER. The --update-pce and --no-prompt flags are ignored for this command. Usage: pcemigrate pce-add [flags] Flags: --name string Name of the PCE. Will be prompted for if left blank. --fqdn string FQDN of the PCE. Will be prompted for if left blank. --port int Port of the PCE. Will be prompted for if not specified. --email string Mail to log into the PCE. Will be prompted for if left blank. --pwd string Password to log into the PCE. Will be prompted for if left blank. --disable-tls-verification Disable tls verification to the PCE. --login-server string Login server. Almost always blank --api-user string API user to log into the PCE. Will be prompted for if left blank. --api-key string API key to log into the PCE. Will be prompted for if left blank. --proxy-server string Set the proxy server to be used to access the PCE. --org int Org id. Will be prompted if not specified. -s, --session Authentication will be a temporary session token. No API Key will be generated. -p, --use-proxy Set a proxy. Can be changed later with the clear-proxy and set-proxy commands. -a, --use-api-key Use pregenerated api credentials from an api key or a service account. -n, --no-auth Do not authenticate to the PCE. Subsequent commands will require PCEMIGRATE_API_USER, PCEMIGRATE_API_KEY, PCEMIGRATE_ORG environment variables to be set. -h, --help Help for pce-add Global Flags (not relevant for all commands): --config-file string Path for the pcemigrate pce.yaml file. --debug Enable debug level logging for troubleshooting. --log-file string Path for the pcemigrate log file. (default "pcemigrate.log") --migrate-op When migrate-op is set to true, the Import operation is interpreted as a copy of objects from a different PCE as part of a PCE migration operation. --no-prompt Remove the user prompt when used with update-pce. --pce string The PCE to use in the command if not using the default PCE. --update-pce This command will update the PCE after a single user prompt. The default will just log potential changes to workloads. --verbose When verbose is enabled, includes the raw API responses. This makes pcemigrate.log increase in size significantly.
Remove a PCE
Remove specific PCE entry parameters from the YAML configuration file.
pce-remove
% ~/pcemigrate/bin/pcemigrate pce-remove --help Removes the pce.yaml file and optionally removes all pcemigrate generated API keys from PCE. The --update-pce and --no-prompt flags are ignored for this command. Usage: pcemigrate pce-remove [name of pce] [flags] Flags: -x, --clear-keys Removes the PCE from the yaml file and clears all pcemigrate generated API credentials from the PCE. -h, --help Help for pce-remove Global Flags (not relevant for all commands): --config-file string The path for the pcemigrate pce.yaml file. --debug Enables debug-level logging for troubleshooting. --log-file string The path for the pcemigrate log file. (default "pcemigrate.log") --migrate-op When migrate-op is set to true, the Import operation is interpreted as a copy of objects from a different PCE as part of a PCE migration operation. --no-prompt Removes the user prompt when used with update-pce. --pce string The PCE to use in the command if not using the default PCE. --update-pce This command will update the PCE after a single user prompt. The default will just log potential changes to workloads. --verbose When verbose is enabled, includes the raw API responses. This makes pcemigrate.log increase in size significantly.
pce.yaml
This is an example of the YAML file. There are two PCE entries with the 4x2testvc49 and mncdevtest6 names assigned to them, respectively.
cat pce.yaml 4x2testvc49: disabletlschecking: false fqdn: 4x2testvc49.ilabs.io key: 5669b123d8e5afdacc964d2bca2e691e94539cddb6a37a5b34efc8a283a76371 org: 1 pce_version: 24.3.0-8933 port: 8443 proxy: "" user: api_14fbdbf3dfd95d871 userhref: ""continue_on_error: false debug: false default_pce_name: 4x2testvc49 log_file: pcemigrate logmax_entries_for_stdout: 100 migrate_op: true mncdevtest6: disabletlschecking: false fqdn: mncdevtest6.ilabs.io key: c85c40126ad961011d141ee82c9b4f2d5033854bd607725523c0d9ae6a3c2d63 org: 196612 pce_version: 24.1.0-1994 port: 8443 proxy: "" user: api_119408df531ee915e userhref: "" no_prompt: false output_format: json target_pce: ""update_pce: false verbose: false
List of PCEs
Displays the list of PCEs added to the YAML configuration file.
pce-list
List all PCEs in pce.yaml. Usage: pcemigrate pce-list [flags] Flags: -h, --help help for pce-list Global Flags (not relevant for all commands): --config-file string The path for the pcemigrate pce.yaml file. --debug Enables debug-level logging for troubleshooting. --log-file string The path for the pcemigrate log file. (default "pcemigrate.log") --migrate-op When migrate-op is set, the Import operation is interpreted as a copy of objects from a different PCE as part of a PCE migration operation. (default true) --no-prompt Removes the user prompt when used with update-pce. --pce string The PCE to use in the command if not using the default PCE. --update-pce This command will update the PCE after a single user prompt. The default will just log potential changes to workloads. --verbose When debug is enabled, includes the raw API responses. This makes pcemigrate.log increase in size significantly.
Set a Proxy
set-proxy
Usage: pcemigrate set-proxy [fqdn:port] [flags] Flags:-h, --help help for set-proxy Global Flags (not relevant for all commands): --config-file string The path for the pcemigrate pce.yaml file. --debug Enables debug-level logging for troubleshooting. --log-file string The path for the pcemigrate log file. (default "pcemigrate.log") --migrate-op When migrate-op is set, the Import operation is interpreted as a copy of objects from a different PCE as part of a PCE migration operation. (default true) --no-prompt Remove the user prompt when used with update-pce. --pce string The PCE to use in the command if not using the default PCE. --update-pce This command will update the PCE after a single user prompt. Default will just log potentially changes to workloads. --verbose When debug is enabled, includes the raw API responses. This makes pcemigrate.log increase in size significantly.
Clear a Proxy
clear-proxy
Usage: pcemigrate set-proxy [fqdn:port] [flags] Flags:-h, --help help for set-proxy Global Flags (not relevant for all commands): --config-file string The path for the pcemigrate pce.yaml file. --debug Enables debug-level logging for troubleshooting. --log-file string The path for the pcemigrate log file. (default "pcemigrate.log") --migrate-op When migrate-op is set, the Import operation is interpreted as a copy of objects from a different PCE as part of a PCE migration operation. (default true) --no-prompt Removes the user prompt when used with update-pce. --pce string The PCE to use in the command if not using the default PCE. --update-pce This command will update the PCE after a single user prompt. Default will just log potential changes to workloads. --verbose When debug is enabled, includes the raw API responses. This makes pcemigrate.log increase in size significantly.