> ## Documentation Index
> Fetch the complete documentation index at: https://developer.copper.co/llms.txt
> Use this file to discover all available pages before exploring further.

# How to launch

<Accordion title="Software requirements" icon="gear">
  In order to operate the dockerized application, an instance of [Copper Unlimited Online](/guides/copper-unlimited-online) must be configured
  with the required wallet shards for the associated fees vault.

  The fees vault service is provided as a Docker image based on `node:lts-alpine` and can be run using [Docker Compose](https://docs.docker.com/compose/).

  The image is publicly available on [Copper DockerHub](https://hub.docker.com/r/copperexchange/hot-wallet).

  Network characteristics of the image:

  * Connects with the Copper API, depending on the chosen `APP_ENVIRONMENT`;
  * Connects with Copper Unlimited Online, depending on the given `APP_CUSTODY_DOCKER_URL` configuration;
</Accordion>

<Steps>
  <Step title="Wallet configuration">
    Before launching, a wallet configuration file must be created. This is a JavaScript file containing a JSON object that describes the wallets that the
    application can sign transactions for. The file is in the following format:

    ```javascript theme={"system"}
    module.exports = [
      {
        portfolioId: '<fees vault account ID>',
        currency: 'ETH',
        walletFilename: 'eth-wallet.copper',
        walletPassword: process.env.ETH_WALLET_PASSWORD,
      },
      {
        portfolioId: '<fees vault account ID>',
        currency: 'TRX',
        walletFilename: 'trx-wallet.copper',
        walletPassword: process.env.TRX_WALLET_PASSWORD,
      },
    ];
    ```

    Any number of wallets can be configured in this file, but each wallet must have the following properties:

    * `portfolioId` - the ID of the fees vault account that the wallet is associated with
    * `currency` - the currency that the wallet is associated with
    * `walletFilename` - the filename of the wallet backup file as used in the Copper Unlimited Online instance
    * `walletPassword` - the password used to encrypt the wallet backup file (in the example given above, this is an environment variable)
  </Step>

  <Step title="Start the app">
    Configure and run the Copper Unlimited Online instance with shards for the configured MPC wallets in your organization's fees vault.
    See the examples in the [Copper Unlimited Online guide](/guides/copper-unlimited-online/how-to-launch).

    To launch the server, use the command below:

    ```bash theme={"system"}
    docker run --rm -ti \
      -v ${PWD}/wallets-config.js:/app/wallets-config.js \
      -e APP_ENVIRONMENT='testnet' \
      -e APP_CUSTODY_DOCKER_URL='{url-of-cu-online}:3010' \
      -e APP_API_KEY='{copper-platform-api-key}' \
      -e APP_API_SECRET='{copper-platform-api-secret}' \
      -e APP_WITHDRAWAL_PASSWORD='{withdrawal-password}' \
      copperexchange/hot-wallet:latest

    # ${PWD}/wallets-config.js is the wallet config file described above.
    # The APP_ENVIRONMENT variable can be 'testnet', 'stage' or 'mainnet' (see details above).
    # The APP_CUSTODY_DOCKER_URL variable is the URL of the CU Online instance that the application will connect to.
    # The APP_API_KEY and APP_API_SECRET variables are the API key and secret that the application will use to connect to the Copper API.
    # The APP_WITHDRAWAL_PASSWORD variable is the withdrawal password of the organization that the application will use to authenticate for withdrawals.
    ```

    After starting the server, it should now be possible to send token transfers from proxy addresses paying the fees from the fees vault account. In this flow,
    orders will be created automatically to cover the fees amounts and the dockerized application will sign and broadcast the transactions to the blockchain.
  </Step>
</Steps>
