# Running both plugins

What changes when GlacierHub and GlacierStaff are installed on the same server.

GlacierHub and GlacierStaff don't depend on each other. Install either one alone and it's complete. Install both on the same server and GlacierStaff listens to GlacierHub's public events, with nothing to configure.

## What connects

| In GlacierHub | Event | In GlacierStaff |
| --- | --- | --- |
| `/msg`, `/reply` | `GlacierHubPrivateMessageEvent` | Social Spy shows the message to staff who have it on |
| `/report` | `GlacierHubPlayerReportEvent` | The report enters the Reports queue, with priority, claim and replay links |

Both plugins also share:

- the same menu style and Frosted Steel defaults
- the same `modules.yml`, `modules/<id>.yml` and `lang/<locale>/` layout
- the same `/glacier<name>` command style with short aliases
- the same API shape: a provider, optional feature getters and module events

## The `report` alias

Both plugins register `report` as an alias: GlacierHub for `/glacierreport`, GlacierStaff for `/glacierstaffreport`. Whichever plugin Bukkit gives the alias to, the report ends up in the GlacierStaff queue, directly or through the event bridge. The full command names always work.

## Using the APIs together

A plugin that depends on both can combine them. For example, hiding the hub sidebar while staff are on duty:

```java
@EventHandler
public void onDuty(StaffModeToggledEvent event) {
    GlacierHubProvider.getIfPresent()
        .flatMap(GlacierHubApi::getScoreboardApi)
        .ifPresent(board -> {
            if (event.isActive()) board.hide(event.getPlayer());
            else board.show(event.getPlayer());
        });
}
```

## On a network

Run GlacierHub on your lobby servers and GlacierStaff on every server where staff work, including the lobbies. To share moderation state between servers, give GlacierStaff a shared database and Redis. See [shared storage](/docs/network/storage) and [Redis](/docs/network/redis).
