Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions nixos/doc/manual/redirects.json
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,27 @@
"module-virtualisation-xen-introduction": [
"index.html#module-virtualisation-xen-introduction"
],
"module-pelican-wings": [
"index.html#module-pelican-wings"
],
"module-pelican-wings-setup": [
"index.html#module-pelican-wings-setup"
],
"module-pelican-wings-traefik": [
"index.html#module-pelican-wings-traefik"
],
"module-pelican-panel": [
"index.html#module-pelican-panel"
],
"module-pelican-panel-traefik": [
"index.html#module-pelican-panel-traefik"
],
"module-pelican-panel-basic-usage": [
"index.html#module-pelican-panel-basic-usage"
],
"module-pelican-panel-environment": [
"index.html#module-pelican-panel-environment"
],
"sec-boot-problems-scripted-stage-1": [
"index.html#sec-boot-problems-scripted-stage-1"
],
Expand Down
2 changes: 2 additions & 0 deletions nixos/doc/manual/release-notes/rl-2611.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@

- [Koito](https://koito.io/), a modern, themeable scrobbler that you can use with any program that scrobbles to a custom ListenBrainz URL. Available as [services.koito](#opt-services.koito.enable).

- [Pelican Panel](https://pelican.dev), a game server management panel. Available as [services.pelican-panel](#opt-services.pelican-panel.enable) and [services.pelican-wings](#opt-services.pelican-wings.enable) (for the control plane).

- [Zapret2](https://github.com/bol-van/zapret2), an extensible DPI bypass program. Available as [services.zapret2](#opt-services.zapret2.enable).

- [FlapAlerted](https://github.com/Kioubit/FlapAlerted), detects BGP flapping events and provides statistics based on BGP update messages. Available as [services.flap-alerted](#opt-services.flap-alerted.enable).
Expand Down
2 changes: 2 additions & 0 deletions nixos/modules/module-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -952,6 +952,8 @@
./services/misc/packagekit.nix
./services/misc/paisa.nix
./services/misc/paperless.nix
./services/misc/pelican-panel.nix
./services/misc/pelican-wings.nix
./services/misc/persistent-evdev.nix
./services/misc/pghero.nix
./services/misc/pinchflat.nix
Expand Down
104 changes: 104 additions & 0 deletions nixos/modules/services/misc/pelican-panel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
# Pelican Panel {#module-pelican-panel}

[Pelican Panel](https://pelican.dev/) is a game server panel forked from [Pterodactyl](https://pterodactyl.io/) which manages Docker containers on multiple machines, using their control plane Wings.
Wings is required to use it and vice versa. To set up Wings, see the docs for [](#opt-services.traefik.enable).

Read the [official docs](https://pelican.dev/docs/panel/getting-started) before continuing.

::: {.note}
Pelican Panel plugins are currently not supported on NixOS.
:::

## Basic Usage {#module-pelican-panel-basic-usage}

```nix
# configuration.nix
{ pkgs, ... }:
{
pelican-panel = {
enable = true;
openFirewall = true;

# Secrets saved like this will be world-readable in the store:
secretEnvironmentFile = pkgs.writeText "secrets.env" ''
APP_KEY="my-super-secret-app-key"
'';
};
}
```

The web installer is disabled by default. This means that you have to create the first admin user yourself. Run

```sh
pelican-artisan p:user:make --admin
```

The `secretEnvironmentFile` option has to be set to the absolute path of a file that exists. Please use a [proper secret management scheme](https://wiki.nixos.org/wiki/Comparison_of_secret_managing_schemes) to provide it.

By default, the panel runs using Caddy on an insecure port ([](#opt-services.pelican-panel.port)). Caddy will not listen on ports 80 and 443.
This is so you can use any reverse proxy, even another webserver like nginx.

## Environment {#module-pelican-panel-environment}

All changes to `.env` will be stored in `/var/lib/pelican`, but it is recommended to configure everything through Nix where possible;
make changes with [](#opt-services.pelican-panel.environment) or [](#opt-services.pelican-panel.secretEnvironmentFile).

## Using traefik as a reverse proxy {#module-pelican-panel-traefik}

The module has support for using traefik as a reverse proxy. See the docs for [](#opt-services.traefik.enable) on how to enable it.
For example, a full configuration could look like this:

```nix
# configuration.nix
{ pkgs, ... }:
{
services = {
pelican-wings = {
# See `services.pelican-wings`
# ...

configuration.remote = "https://panel.example.com";
};

pelican-panel = {
enable = true;

enableTraefik = true;
domain = "https://panel.example.com";

secretEnvironmentFile = pkgs.writeText "secrets.env" ''
APP_KEY="my-super-secret-app-key"
'';
};

traefik = {
enable = true;

staticConfigOptions = {
entryPoints = {
web = {
address = ":80";

# Redirect http to https
http.redirections.entryPoint = {
to = "websecure";
scheme = "https";
};
};

websecure = {
address = ":443";
};
};

certificatesResolvers.letsencrypt.acme = {
email = "alice@example.com";
storage = "/var/lib/traefik/acme.json";
tlsChallenge = { };
};
};
};
};
}
```

Loading
Loading