# Commands

The Angus command-line interface (CLI) provides a set of commands to manage and interact with Angus environments. This section provides an overview of the available commands and their usage.

# angusctl init

Initializes the Angus ctl environment.

angusctl init

# angusctl registry list

List images from the Angus Center registry. Raises exception.AngusCliException If the response status code is 500.

angusctl registry list

# angusctl registry push

Pushes a Docker image to the Angus Center registry. The function checks if the image has been tagged with a specific registry URL. If the image is not tagged with the registry URL, an error message is displayed and the function exits. If there is an authorization error (status code 401) when retrieving registry credentials, an error message is displayed and the function exits.

Args:

  • -i image (str): The name of the Docker image to push.
  • -t tag (str): The tag of the Docker image to push.
angusctl registry push

# angusctl dev doctor

Examines and verifies the current environment and provides recommendations for tools or fixing issues.

angusctl dev doctor

# angusctl dev create

Creates a new Angus project directory structure and populates it with template files.

Args:

  • -n name (str): The name of the project to be created.
angusctl dev create

# angusctl cluster info

Display information about the current Kubernetes cluster that houses the Angus Ecosystem. This function performs several checks to verify the status and access permissions of the Kubernetes cluster. It checks the following:

  1. Cluster access: Verifies if the cluster can be accessed.
  2. Permissions: Placeholder for verifying user permissions.
  3. Spaces: Lists the available spaces in the cluster.
  4. Resources: Placeholder for verifying cluster resources.
  5. Angus server access: Placeholder for verifying access to the Angus server.
angusctl cluster info

# angusctl cluster init

Initializes the Angus Ecosystem by creating necessary Kubernetes namespaces and secrets.

Args:

  • -ips imagepullsecretonly (bool): If True, only the image pull secret will be created.
  • -ss serversecretonly (bool): If True, only the server secret will be created.
angusctl cluster init

# angusctl channel getChannelConfiguration

Fetches the configuration of a specified channel from the server.

Args:

  • -c channel (str): The name of the channel whose configuration is to be fetched.
  • -s space (str): The space to which the channel belongs.
angusctl channel getChannelConfiguration

# angusctl channel channelList

Fetches the list of channels for a given space and peer.

Args:

  • -s space (str): The space identifier for which to retrieve the channel list.
  • -p peer (str): The peer identifier associated with the space.
angusctl channel channelList

# angusctl channel generateUpdatePb

Generates a protobuf update for a specified channel and saves it to a file.

Args:

  • -c channel (str): The name of the channel for which the update is being generated.
  • -s space (str): The space associated with the channel.
  • -m mspname (str): The MSP (Membership Service Provider) name.
  • -j orgjson (str): The path to the JSON file containing the organization details.
  • -o out (str): The path where the generated protobuf update file will be saved.
angusctl channel generateUpdatePb

# angusctl channel modifyBatch

Modify a batch of parameters for a specified channel and save the response to a file.

Args:

  • -c channel (str): The name of the channel to modify.
  • -s space (str): The space associated with the channel.
  • -m mspname (str): The name of the MSP (Membership Service Provider).
  • -j paramname (str): The name of the parameter to modify.
  • -j paramvalue (str): The new value for the parameter.
  • -o out (str): The output file path to save the response content.
angusctl channel modifyBatch

# angusctl channel signUpdatePb

Signs a protocol buffer (pb) update for a specified channel and space, and writes the signed update to an output file.

Args:

  • -s space (str): The space identifier.
  • -c channel (str): The channel identifier.
  • -p pb (str): The path to the protocol buffer file to be signed.
  • -o out (str): The path where the signed protocol buffer file will be written.
angusctl channel signUpdatePb

# angusctl channel update

Updates a channel with the provided parameters.

Args:

  • -c channel (str): The name of the channel to update.
  • -s space (str): The space associated with the channel.
  • -m mspname (str): The MSP (Membership Service Provider) name.
  • -p pb (str): The path to the protobuf file to be uploaded.
angusctl channel update

# angusctl chaincode queryInstalled

Queries the installed chaincode on the server and prints the response content.

Args:

  • -s space (str): The space identifier where the chaincode is installed.
  • -c chaincode (str): The name of the chaincode to query.
angusctl chaincode queryInstalled

# angusctl chaincode checkCommitReadiness

Check the commit readiness of a specified chaincode in a given space and prints the response in a formatted manner.

Args:

  • -s space (str): The space in which the chaincode is located.
  • -c chaincode (str): The name of the chaincode to check for commit readiness.
angusctl chaincode queryInstalled

# angusctl chaincode commit

Commits the specified chaincode to the given space.

Args:

  • -s space (str): The name of the space where the chaincode will be committed.
  • -c chaincode (str): The name of the chaincode to commit.
angusctl chaincode commit

# angusctl chaincode queryCommitted

Queries the committed chaincode from the server.

Args:

  • -s space (str): The space identifier for the query.
  • -c chaincode (str): The name of the chaincode to query.
angusctl chaincode queryCommitted

# angusctl chaincode invoke

Invokes a chaincode on the specified space.

Args:

  • -s space (str): The space in which the chaincode is to be invoked.
  • -c chaincode (str): The name of the chaincode to invoke.
  • -i init (str): Initialization parameters for the chaincode.
angusctl chaincode invoke

# angusctl login

Authenticates the user with the provided username and password, and stores the access, ID, and refresh tokens.

Args:

  • -u username (str): The username for authentication.
  • -p password (str): The password for authentication.
angusctl login

# angusctl logout

Logs the user out by removing authentication token files. This function checks for the existence of token files used for authentication and removes them if they exist. It then prints a message indicating that the user has been logged out and provides instructions for logging in again.

angusctl logout

# angusctl info

Fetch and display Angus subscription status information.

angusctl info