prepare

Function prepare 

Source
pub fn prepare(args: AppArgs) -> Result<PreparedApp>
Expand description

Prepares the application for running.

This function performs the following steps:

  1. Finds free ports if not specified.
  2. Configures logging.
  3. Prints a start banner.
  4. Creates the data directory.
  5. Loads or generates the user’s identity.
  6. Prints identity information.
  7. Opens the database.
  8. Sets up storage encryption if enabled.

§Arguments

  • args - The command-line arguments.

§Errors

This function will return an error if any of the setup steps fail.