Pterodactyl
Pterodactyl® is a free, open-source game server management panel built with PHP, React, and Go. Designed with security in mind, Pterodactyl runs all game servers in isolated Docker containers while exposing a beautiful and intuitive UI to end users.
You can follow my guide on the public documentation site to replicate my set up :)
Flowchart
Software Level
This flowchart shows how the apps integrate
Hardware Level
This flowchart shows what lives where
Panel
The Panel is hosted on Cocoa, as a docker container
The Panel stack is made up of 3 containers,
Redis
MariaDB
Panel Application
version: '3.8'
services:
database:
image: mariadb:10.11
restart: always
#ports:
#- 3306:3306
command: --default-authentication-plugin=mysql_native_password
volumes:
- db:/var/lib/mysql
- dbetc:/etc/mysql
networks:
- panel
environment:
MYSQL_PASSWORD: $MYSQL_PASS
MYSQL_ROOT_PASSWORD: $MYSQL_PASS_ROOT
MYSQL_DATABASE: "panel"
MYSQL_USER: "pterodactyl"
healthcheck:
test: ["CMD", "mariadb-admin", "ping", "-proot", "--password=$MYSQL_PASS_ROOT"]
interval: 30s
timeout: 10s
retries: 5
labels:
- "autoheal=true"
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
cache:
image: redis:alpine3.18
networks:
- panel
restart: always
volumes:
- cache:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 5
labels:
- "autoheal=true"
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
panel:
image: ghcr.io/pterodactyl/panel:v1.11.7
restart: always
networks:
- panel
ports:
- ${PORT_HTTP:-80}:80
#dns:
# - 1.1.1.1
links:
- database
- cache
volumes:
- env:/app/var
environment:
MAIL_FROM: $MAIL_FROM
MAIL_DRIVER: "smtp"
MAIL_HOST: ${MAIL_SERVER:-smtp.gmail.com}
MAIL_PORT: ${MAIL_PORT:-587}
MAIL_USERNAME: $MAIL_USERNAME
MAIL_PASSWORD: $MAIL_PASS
MAIL_ENCRYPTION: "true"
APP_URL: $PTERO_PANEL_URL
APP_TIMEZONE: $TZ
APP_SERVICE_AUTHOR: $MAIL_FROM
TRUSTED_PROXIES: "*"
DB_PASSWORD: $MYSQL_PASS
APP_ENV: "production"
APP_ENVIRONMENT_ONLY: "false"
CACHE_DRIVER: "redis"
SESSION_DRIVER: "redis"
QUEUE_DRIVER: "redis"
REDIS_HOST: "cache"
DB_HOST: "database"
DB_PORT: "3306"
HASHIDS_SALT: $HASHIDS_SALT #Refer to https://github.com/pterodactyl/panel/issues/5012#issuecomment-1960789655
HASHIDS_LENGTH: 8
healthcheck:
test: curl --connect-timeout 15 --silent --show-error --fail localhost:80
interval: 1m
timeout: 30s
retries: 3
start_period: 30s
labels:
- "autoheal=true"
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
networks:
panel:
volumes:
cache:
db:
env:
dbetc:
Redis
Randomly Generated
/data
Stores the cached files... I assume?
MariaDB
/srv/pterodactyl/database
/var/lib/mysql
Database location
Panel
809
WebUI HTTP
4439
WebUI HTTPS (not used)
pteropanel_var
/app/var
Contains configuration .env file
pteropanel_nginx
/etc/ngix/http.d
pteropanel_certs
/etc/letsencrypt
pteropanel_logs
/apps/storage/logs
Mocha
Connect to the Wings container to manage servers
Wings
Wings is Pterodactyl's server control plane, built for the rapidly changing gaming industry and designed to be highly performant and secure. Wings provides an HTTP API allowing you to interface directly with running server instances, fetch server logs, generate backups, and control all aspects of the server lifecycle.
This app is hosted on Mocha and Cola as a docker container
This stack is made up of 2 containers,
Wings
MariaDB
version: '3.8'
services:
wings:
image: ghcr.io/pterodactyl/wings:v1.11.13
restart: always
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
networks:
- wings
ports:
- ${PORT_SFTP:-2022}:2022
- ${PORT:-443}:443 #Web address port
#- $PORT_UNKNOWN:8080
tty: true
environment:
TZ: $TZ
WINGS_UID: 988
WINGS_GID: 988
WINGS_USERNAME: pterodactyl
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /var/lib/docker/containers/:/var/lib/docker/containers/
- config:/etc/pterodactyl/ #config file from Panel
- /var/lib/pterodactyl/:/var/lib/pterodactyl/ #game server files
- /var/log/pterodactyl/:/var/log/pterodactyl/ #Allows Crowdsec to read logs
- /tmp/pterodactyl/:/tmp/pterodactyl/
- /srv/daemon-data/:/srv/daemon-data/
- logs:/app/storage/logs/ #Laravel log files
db:
image: mariadb:10.11
restart: always
command: --default-authentication-plugin=mysql_native_password
ports:
- $PORT_DB:3306
networks:
- wings
volumes:
- db:/var/lib/mysql
environment:
- MYSQL_DATABASE="servers"
- MYSQL_USER="pterodactyl"
- MYSQL_PASSWORD=$SQL_PASS
- MYSQL_ROOT_PASSWORD=$SQL_PASS_ROOT
healthcheck:
test: ["CMD", "mariadb-admin", "ping", "-proot", "--password=$MYSQL_PASS_ROOT"]
interval: 30s
timeout: 10s
retries: 5
labels:
- "autoheal=true"
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
networks:
wings:
name: wings
driver: bridge
driver_opts:
com.docker.network.bridge.name: wings
pterodactyl_nw:
driver: bridge
volumes:
config:
lib:
daemon:
db:
logs:
Wings
443
Panel Connection Port (Cloudflare Tunnel)
2022
SFTP
8080
Daemon port (unused)
/var/run/docker.sock
/var/run/docker.sock
Manage Docker containers ( servers)
/var/lib/docker/containers/
var/lib/docker/containers/
etc
/etc/pterodactyl/
Config file lives here
/var/lib/pterodactyl/
/var/lib/pterodactyl/
/var/log/pterodactyl/
/var/log/pterodactyl/
/tmp/pterodactyl/
/tmp/pterodactyl/
/srv/daemon-data/
/srv/daemon-data/
Panel
Panel manages wings instance
MariaDB
3306
Port to access Database
db
/var/lib/mysql
Database location
Panel
Panel manages database
Last updated
Was this helpful?