decred.org/dcrdex@v1.0.5/docs/wiki/Client-Installation-and-Configuration.md (about)

     1  # Client Installation and Configuration
     2  
     3  ## Client Quick Start Installation
     4  
     5  Bison Wallet can be installed in one of the following ways. Download the
     6  application from *just one* of the following locations:
     7  
     8  * Download standalone Bison Wallet for your operating system for the [latest
     9    release on GitHub](https://github.com/decred/dcrdex/releases). Extract the
    10    "bw" executable from the archive and run it. Open any web browser to the
    11    link shown by the application. You may also put the **bisonw** executable's
    12    folder on your `PATH`.
    13  * [Use Decrediton](https://docs.decred.org/wallets/decrediton/decrediton-setup/),
    14    the official graphical Decred wallet, which integrates Bison Wallet, and go
    15    to the DEX tab.
    16  * (Legacy users) Use the Decred command line application installer,
    17    [**dcrinstall**](https://docs.decred.org/wallets/cli/cli-installation/). This
    18    is no longer recommended.
    19  * Build the standalone client [from source](https://github.com/decred/dcrdex/wiki/Client-Installation-and-Configuration#advanced-client-installation).
    20  
    21  **WARNING**: If you decide to build from source, use the latest release branch,
    22  not `master`.
    23  
    24  ### Important Note on External Wallets
    25  
    26  If using external wallet software (e.g. **dcrd**+**dcrwallet**, **bitcoind**,
    27  Electrum, etc.), they must remain running while Bison Wallet is running. Do
    28  not shut down, lock, unlock, or otherwise modify your wallet settings while the
    29  client is running. Also, only send funds from within the DEX application, not
    30  directly from the external wallet's own controls. Finally, do not manually lock
    31  or unlock any coins while Bison Wallet is running.
    32  
    33  ## Client Configuration
    34  
    35  These instructions assume you've obtained Bison Wallet as described in the
    36  [Wallet Quick Start Installation](#client-quick-start-installation) section.
    37  
    38  ### Prerequisites
    39  
    40  If you use the standalone Bison Wallet, you will need a web browser to open
    41  Bison Wallett user interface as described in the next section.
    42  
    43  Most users will use the native wallets that are already built into the DEX
    44  client. Depending on the asset, you may be able to choose from: (1) a native
    45  wallet, (2) an external full node wallet, or (3) an Electrum-based wallet.
    46  Consult the following table for a summary of wallet support. If there is a
    47  checkmark in the "native" column, no external software is required.
    48  
    49  | Coin         | native | full node | Electrum | notes                        |
    50  |--------------|--------|-----------|----------|------------------------------|
    51  | Bitcoin      |    ✓   | [v27.0](https://bitcoincore.org/en/download/) | [v4.5.5](https://electrum.org/) |                              |
    52  | Decred       |    ✓   | [v2.0.3](https://github.com/decred/decred-release/releases) |     x    |                              |
    53  | Ethereum     |    ✓   | geth IPC/http/ws |   N/A   |  see <https://github.com/decred/dcrdex/wiki/Ethereum>   |
    54  | Litecoin     |    ✓   | [v0.21.2.1](https://litecoin.org/) | [v4.2.2](https://electrum-ltc.org/) | |
    55  | Bitcoin Cash |    ✓   | [v27.0.0](https://bitcoincashnode.org/) |     x    | use only Bitcoin Cash Node for full node |
    56  | Dogecoin     |    x   |  [v1.14.7.0](https://dogecoin.com/) |     x    |                              |
    57  | Zcash        |    x   |   [v5.4.2](https://z.cash/download/)  |     x    |                              |
    58  | Dash         |    x   |  [v20.1.1](https://github.com/dashpay/dash/releases)  |     x    | |
    59  | Firo         |    x   | [v0.14.14.0](https://github.com/firoorg/firo/releases) | [v4.1.5.5](https://github.com/firoorg/electrum-firo/releases) | |
    60  
    61  NOTE: The Electrum option is less mature and provides less privacy than the
    62  other wallet types. Some manual configuration of the Electrum wallet's RPC
    63  server is also necessary ([example](images/electrum-rpc-config.png)).
    64  
    65  ### Synchronizing Wallets
    66  
    67  **If using the native wallets** that are integrated with Bison Wallet (see
    68  above), you can skip this section.
    69  
    70  If you choose to use an external wallet (full node or Electrum), you must start
    71  and synchronize them with their networks *before* running Bison Wallet.
    72  
    73  Note that Bitcoin Core and most "clones" support block pruning, which can keep
    74  your blockchain storage down to a few GB, not the size of the full blockchain,
    75  but a large size should be used to avoid full reindexing if used infrequently.
    76  Also, for good network fee estimates, the full node should be running for
    77  several blocks.
    78  
    79  ### Initial Setup
    80  
    81  1. Start the client. For installed versions, open through your system applications menu.
    82     For standalone Bison Wallet (**bisonw**), open a command prompt
    83     in the folder containing the bisonw application and run it. e.g. `./bisonw` on
    84     Mac and Linux, or `bisonw.exe` on Windows. To avoid the command prompt on
    85     Windows, `bisonw-tray.exe` may be run instead. If using Decrediton instead of
    86     **bisonw**, just click the "DEX" tab and skip to step 3.
    87  
    88     **Note**: You can start bisonw with another network via a command line flag:
    89     `--testnet` or `--simnet`, the default is `mainnet`.
    90  
    91  2. In your web browser, navigate to <http://localhost:5758>. Skip this step if
    92     using Decrediton.
    93  
    94     <img src="images/omnibar-client.png" width="320">
    95  
    96  3. Set your new **client application password**. You will use this password to
    97     perform all future security-sensitive client operations.
    98  
    99     <img src="images/client-pw.png" width="320">
   100  
   101     NOTE: Checking the "Remember my password" box only applies to the current
   102     session. It is easiest for most users to have it checked.
   103  
   104  4. After creating your app password, you'll be taken to the `Quick Configuration` form:
   105  
   106     <img src="images/quick-config.png" width="350">
   107  
   108     The selected native wallets will be created for you and you'll be connected
   109     to the selected DEX server when you submit the form.
   110  
   111     **Note**: If you encounter an error about not being able to connect to the
   112     selected DEX server during the quick configuration, you can manually [add the DEX server](https://github.com/decred/dcrdex/wiki/DEX-Trading-Account-Management#adding-a-dex-trading-account). You will see a list of known DEX server(s) you can choose from.
   113  
   114  5. Backup your app seed. This seed is used to restore your DEX accounts and any
   115     native wallets, so keep it safe.
   116  
   117     If you skip this step now (not recommended), you can go to the Settings view
   118     via the "gears" icon in the top navigation bar to retrieve your application
   119     seed later.
   120  
   121      <img src="images/view-seed.png" width="360">
   122  
   123  6. That's it! You'll be redirected to the wallets page after step 4 above.
   124  
   125  7. To start trading, follow the guide to [Setting Up Your DEX Trading
   126     Account](https://github.com/decred/dcrdex/wiki/DEX-Trading-Account-Management).
   127  
   128  ## Advanced Client Installation
   129  
   130  ### Dependencies
   131  
   132  1. [Go 1.19 or 1.20](https://golang.org/doc/install)
   133  2. (optional) [Node 18 or 20](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) is used to bundle resources for the browser interface. It's important to note that Bison Wallet has no external JavaScript dependencies. The client doesn't import any Node packages. We only use Node to lint and compile our own JavaScript and css resources. This build step is not required if building from a release branch such as `release-v0.6`.
   134  3. At least 2 GB of available system memory.
   135  
   136  ### Build from Source
   137  
   138  **Build the web assets** from *client/webserver/site/*.
   139  
   140  **If building from the `master` branch,** bundle the CSS and JavaScript with Webpack:
   141  
   142  ```sh
   143  npm clean-install && npm run build
   144  ```
   145  
   146  **Build and run the client** from *client/cmd/bisonw*.
   147  
   148  ```sh
   149  go build
   150  ./bisonw
   151  ```
   152  
   153  Connect to the client from your browser at `localhost:5758`.
   154  
   155  While `bisonw` may be run from within the git workspace as described above, the
   156  `bisonw` binary executable generated with `go build` can be copied into a
   157  different folder (e.g. `/opt/dcrdex/bisonw`).
   158  
   159  ### Docker
   160  
   161  #### Build the docker image
   162  
   163  ```sh
   164  docker build -t user/dcrdex -f client/Dockerfile .
   165  ```
   166  
   167  #### Create docker volume
   168  
   169  ```sh
   170  docker volume create --name=dcrdex_data
   171  ```
   172  
   173  #### Run image
   174  
   175  ```sh
   176  docker run -d --rm -p 127.0.0.1:5758:5758 -v dcrdex_data:/root/.bisonw user/dcrdex
   177  ```