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

# Quickstart

> Get your network onto a single shared Nexo pack in about ten minutes.

You need a Velocity, BungeeCord or Waterfall proxy and at least one Paper or Folia
backend with [Nexo](https://nexomc.com) already installed and working.

<Steps>
  <Step title="Install NexoHub on the proxy">
    Drop the jar for your proxy into its `plugins/` folder and start it:
    `NexoHubVelocity.jar` on Velocity, `NexoHubBungee.jar` on BungeeCord or Waterfall.

    On first start it creates `plugins/nexohub/config.yml` and generates a secret into
    it. On BungeeCord the folder is `plugins/NexoHub/`; everything else is the same, and
    the rest of this site writes it `plugins/nexohub/` for both. Copy that value; you need it on every backend.

    ```
    [nexohub]: Generated a hub secret and stored it in config.yml.
    [nexohub]: Put this in each backend's plugins/NexoHubBridge/config.yml: secret: "..."
    ```
  </Step>

  <Step title="Decide where the pack is hosted, or do not">
    Nothing to do here on a fresh install. The pack is uploaded to Hermes, Nexo's own
    host, and every backend hands players that link, so there is no port to open and no
    address to get right.

    ```yaml theme={null}
    packs:
      host: hermes
    ```

    To serve the pack from the proxy itself instead, set `host: proxy` and fill in the
    address players will use:

    ```yaml theme={null}
    http:
      public_address: "http://your.proxy.address:8085"
    ```

    <Warning>
      Under `host: proxy` that address ends up in the resource pack link sent to every
      player, so it has to be reachable from the internet and the port has to be open in
      your firewall. Left blank, NexoHub falls back to localhost, which only works for
      testing on your own machine.
    </Warning>

    See [where the pack is hosted](/guides/hosting) for the other hosts and for what
    multipack needs.
  </Step>

  <Step title="Install the bridge on each backend">
    Drop `NexoHubBridge.jar` into each backend's `plugins/` folder, next to Nexo.

    In `plugins/NexoHubBridge/config.yml`:

    ```yaml theme={null}
    hub:
      address: "http://your.proxy.internal:8085"
      secret: "the secret from step 1"
    server_name: auto
    ```

    That is the only file you edit. Nexo's own `Pack.server.type` is set to `HUB` for
    you on the first start that finds a `settings.yml`, before Nexo has read it.

    Restart the backends. The hub is still empty and nobody has joined yet, so each one
    says so and waits:

    ```
    [NexoHubBridge] Set Pack.server.type: HUB in plugins/Nexo/settings.yml, so this backend uses the hub.
    [NexoHubBridge] This backend's name is not known yet, so nothing was pulled. Set server_name in config.yml, or leave it on auto and the proxy will teach it on the first player join.
    [NexoHubBridge] Registered the HUB pack server with Nexo.
    Nexo | PackServer set to HUB
    ```

    <Note>
      Written once, then left alone. Setting it back by hand at any point takes that
      backend out of the network and the bridge will not undo it. On a backend where Nexo
      has never run there is no `settings.yml` to write into yet, so the bridge says it
      will do it on the next start and does.
    </Note>

    <Note>
      Leave `server_name: auto`. The proxy tells each backend what it is called the first
      time a player joins, so the name only ever lives in your proxy's own server list:
      `velocity.toml`, or BungeeCord's `config.yml`.
    </Note>
  </Step>

  <Step title="Fill the hub from one backend">
    Join the network, then on the proxy name the backend whose `plugins/Nexo/` the whole
    network should build from:

    ```
    /nexohub adopt lobby
    ```

    ```
    [NexoHub] Asked lobby for its plugins/Nexo/ folder.
    [NexoHub] Watch the console. Generated output is left behind, so run /nexohub validate afterwards.
    ```

    That backend sends its folder up:

    ```
    [NexoHubBridge] Sending 118 file(s), 2412 KiB, to the hub as 'lobby'.
    [NexoHubBridge] The hub took these files; they are what the whole network builds from now.
    ```

    ```
    [nexohub]: Adopted 118 file(s) from lobby into _shared/.
    ```

    <Warning>
      Join the network before you run this. On `server_name: auto` a backend does not know
      its own name until a player joins, and it cannot be adopted from until it does. The
      request expires after five minutes.
    </Warning>

    <Note>
      Adopting overwrites `_shared/` with that one backend's files, so every other backend
      is about to be given them. If your servers have drifted apart, decide which one to
      name first: see [moving an existing network](/guides/migrating).
    </Note>

    <Accordion title="Or copy the files up yourself">
      You can fill `nexo-data/` over SFTP instead, at any point. Copy the contents of one
      backend's `plugins/Nexo/` folder into `plugins/nexohub/nexo-data/_shared/`, keeping
      the same layout:

      ```
      plugins/nexohub/nexo-data/
      └── _shared/
          ├── items/
          ├── glyphs/
          ├── recipes/
          ├── pack/assets/
          └── settings.yml
      ```

      Skip anything generated: `pack/pack.zip`, everything under `pack/external_packs/`,
      and hidden folders such as `.assetCache/`. NexoHub handles plugin packs separately,
      see [plugin packs](/guides/plugin-packs).
    </Accordion>
  </Step>

  <Step title="Check every backend picked it up">
    The hub pushes the moment it has files, so every other backend receives them without
    a restart:

    ```
    [NexoHubBridge] Applied bundle a1b2c3d4, 118 file(s) into plugins/.
    [NexoHubBridge] Uploaded pack 5e6f7a8b (153 KiB) to the hub.
    ```

    On the second and later backends the upload turns into a skip:

    ```
    [NexoHubBridge] Hub already holds pack 5e6f7a8b, skipping upload.
    ```

    Then run `/nexohub status` on the proxy:

    ```
    [NexoHub] NexoHub, pack hosting delegated to HERMES
      lobby [3p] bundle a1b2c3d4 in sync
          pack 5e6f7a8b  Nexo 1.26.0/26.2  (last heard 12s ago)
      pvp [1p] bundle a1b2c3d4 in sync
          pack 5e6f7a8b  Nexo 1.26.0/26.2  (last heard 8s ago)
    [NexoHub] 1 pack(s) stored, keeping 5.
    ```
  </Step>

  <Step title="Check the rest of it">
    ```
    /nexohub doctor
    ```

    This tests the things you cannot see from where you are standing. On `host: proxy`
    the most important of them is whether the address in your resource pack link answers
    from outside your own network; on the default delegated hosting there is no address
    of yours to test and it says so.

    ```
    [NexoHub] Checking...
      ok   everything under nexo-data/ parses
      note pack hosting is delegated to HERMES, so public_address is unused
      ok   no port here needs to face the internet; players fetch the pack from HERMES
      ok   all 2 backend(s) have reported in
      ok   no backend reports a failed reload
      ok   backends agree on their Nexo and Minecraft versions
      ok   every backend on the same files serves the same pack
      note plugins/nexohub/ uses 4 MiB (1 pack(s), 1 snapshot(s))
    [NexoHub] No problems found.
    ```
  </Step>
</Steps>

## From now on

Edit any file under `nexo-data/` and save. Within a few seconds every backend pulls the
change, reloads Nexo, and players get the updated pack. You do not need to run a command
or restart anything.

<Check>
  Nothing is pushed unless it parses first. If you mistype a line, your backends stay on
  the last files that worked and the error goes to your console instead of to your players.
  See [not breaking your network](/guides/safety).
</Check>

A backend with nobody on it cannot be sent a message, so it asks the hub for changes on
its own every minute. It reports what it has on the same request, so an empty server
still shows up correctly in `/nexohub status`.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.