We highly recommend to create a custom docker network VLAN for this service. The command below is our recommendation for networking
docker network create --subnet=10.0.31.0/24 --gateway=10.0.31.1 --ip-range=10.0.31.0/24 --driver=bridge --attachable=true gamelan
cd /home/myusername/docker
mkdir pterodactyl && cd "$_"
mkdir -p /wings/data/lib /wings/data/tmp/pterodactyl
services:
db:
image: mariadb:latest
container_name: pterodactyl_mariadb
restart: unless-stopped
command: --default-authentication-plugin=mysql_native_password
volumes:
- ./panel/db:/var/lib/mysql
environment:
MYSQL_DATABASE: panel
MYSQL_USER: pterodactyl
MYSQL_PASSWORD: pterodactyl!
MYSQL_ROOT_PASSWORD: pterodactyl!!
networks:
- gamelan
cache:
image: redis:alpine
container_name: pterodactyl_redis
restart: unless-stopped
networks:
- gamelan
panel:
image: ghcr.io/pterodactyl/panel:latest
container_name: pterodactyl_panel
restart: unless-stopped
stdin_open: true
tty: true
ports:
- 8180:80
# - 8184:443 # OPTIONAL
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /var/lib/docker/containers:/var/lib/docker/containers
- /etc/ssl/certs:/etc/ssl/certs:ro
- ./panel/conf/certs:/etc/letsencrypt #
- ./panel/conf/etc:/etc/pterodactyl
- ./panel/conf/nginx:/etc/nginx/http.d #
- ./panel/data/var:/app/var #
- ./panel/data/logs/panel:/app/storage/logs #
- ./panel/data/logs/panel:/var/log/panel/logs
- ./panel/data/panel:/var/www/html
- ./panel/data/lib:/var/lib/pterodactyl
environment:
RECAPTCHA_ENABLED: false
TZ: Etc/UTC
APP_TIMEZONE: Etc/UTC
APP_ENV: production
APP_ENVIRONMENT_ONLY: false
APP_URL: https://gpanel.DOMAIN.COM
APP_SERVICE_AUTHOR: [email protected]
MAIL_FROM: [email protected]
MAIL_DRIVER: smtp
MAIL_HOST: mail.DOMAIN.COM
MAIL_PORT: 587
MAIL_USERNAME: [email protected]
MAIL_PASSWORD: REPLACE_WITH_YOUR_EMAIL_PASSWORD
MAIL_ENCRYPTION: false
TRUSTED_PROXIES: "*"
PTERODACTYL_TELEMETRY_ENABLED: false
DB_HOST: db
DB_PORT: 3306
DB_PASSWORD: pterodactyl!
CACHE_DRIVER: redis
SESSION_DRIVER: redis
QUEUE_DRIVER: redis
REDIS_HOST: cache
# LE_EMAIL: "" # Uncomment if you want to use Let's Encrypt to generate an SSL certificate for the Panel.
networks:
- gamelan
wings:
image: ghcr.io/pterodactyl/wings:latest
container_name: pterodactyl_wings
restart: unless-stopped
ports:
- 8181:8080
- 8182:2022 # SFTP
# - 8183:443 # OPTIONAL
stdin_open: true
tty: true
environment:
TZ: Etc/UTC
APP_TIMEZONE: Etc/UTC
WINGS_UID: 1000
WINGS_GID: 1000
WINGS_USERNAME: pterodactyl
volumes:
- /var/run/docker.sock:/var/run/docker.sock #
- /var/lib/docker/containers:/var/lib/docker/containers # - ./panel/data/containers:/var/lib/docker/containers
- /etc/ssl/certs:/etc/ssl/certs:ro #
- ./wings/conf/etc:/etc/pterodactyl #
- /wings/data/lib:/wings/data/lib #
- ./wings/data/logs/wings:/var/log/pterodactyl #
- /wings/data/tmp/pterodactyl:/wings/data/tmp/pterodactyl #
# - ./wings/data/lib/wings.db:/wings/data/lib/wings.db
networks:
- gamelan
networks:
gamelan:
external: true
docker compose up -d
cd /home/myusername/docker/pterodactyl
docker compose run --rm panel php artisan p:user:make [email protected] --username=admin --name-first=admin --name-last=user --password=admin --admin=1 --no-password
Go to: Admin > Locations
Click on: Create new
Name it: home
Go to: Admin --> Nodes
Click on: Create new
Insert the following settings then click on Create Node:
Settings
Name: gpanel-node01.DOMAIN.COM
Location: home
FQDN: gpanel-node01.DOMAIN.COM
Communicate Over SSL: Use SSL Connection
Behind Proxy: Behind Proxy
Allocation Limits
Total Memory: 10240 Overallocate: 0
Disk Space: 102400 Overallocate: 0
General Configuration
Daemon Port: 443
Daemon SFTP Port 2022
configurationcd /home/myusername/docker/pterodactyl
nano wings/conf/etc/config.yml
debug: false
app_name: Pterodactyl
uuid: UUID_ID_HERE
token_id: TOKEN_ID_HERE
token: TOKEN_HERE
api:
host: 0.0.0.0
port: 8080
ssl:
enabled: false
cert: /etc/letsencrypt/live/gpanelnode.DOMAIN.COM/fullchain.pem
key: /etc/letsencrypt/live/gpanelnode.DOMAIN.COM/privkey.pem
disable_remote_download: false
upload_limit: 100
trusted_proxies: []
system:
root_directory: /wings/data/lib
log_directory: /var/log/pterodactyl
data: /wings/data/lib/volumes
archive_directory: /wings/data/lib/archives
backup_directory: /wings/data/lib/backups
tmp_directory: /wings/data/tmp/pterodactyl
username: pterodactyl
timezone: Etc/UTC
user:
rootless:
enabled: false
container_uid: 0
container_gid: 0
uid: 1000
gid: 1000
disk_check_interval: 150
activity_send_interval: 60
activity_send_count: 100
check_permissions_on_boot: true
enable_log_rotate: true
websocket_log_count: 150
sftp:
bind_address: 0.0.0.0
bind_port: 2022
read_only: false
crash_detection:
enabled: true
detect_clean_exit_as_crash: true
timeout: 60
backups:
write_limit: 0
compression_level: best_speed
transfers:
download_limit: 0
openat_mode: auto
docker:
network:
interface: 10.0.31.1
dns:
- 1.1.1.1
- 1.0.0.1
name: gamelan
ispn: false
driver: bridge
network_mode: gamelan
is_internal: false
enable_icc: true
network_mtu: 1500
interfaces:
v4:
subnet: 10.0.31.0/24
gateway: 10.0.31.1
v6:
subnet: fdba:17c8:6c94::/64
gateway: fdba:17c8:6c94::1011
domainname: ""
registries: {}
tmpfs_size: 100
container_pid_limit: 512
installer_limits:
memory: 1024
cpu: 100
overhead:
override: false
default_multiplier: 1.05
multipliers: {}
use_performant_inspect: true
userns_mode: ""
log_config:
type: local
config:
compress: "false"
max-file: "1"
max-size: 5m
mode: non-blocking
throttles:
enabled: true
lines: 2000
line_reset_interval: 100
remote: https://gpanel.DOMAIN.COM
remote_query:
timeout: 30
boot_servers_per_page: 50
allowed_mounts: []
allowed_origins:
- '*'
allow_cors_private_network: true
ignore_panel_config_updates: false
docker compose restart wings
Go to: Admin --> Nodes
Click on the node
Click on: Allocation
For Assign New Allocations insert the following then click on Submit:
IP Address: 0.0.0.0
IP Alias: Minecraft Servers
ports: 25565-25599
Go to: Admin > Servers
Click on: Create new
Insert the following then click on Create Server:
Core Details
Server Name: Minecraft Vanilla
Server Owner: admin email you are logged in with
Server Description: A Minecraft Vanilla Server
Resource Management
Memory: 2048
Disk Space: 2048
nano /home/myusername/docker/traefik-crowdsec/traefik-data/fileConfig.yml
http:
routers:
### pterodactyl - router ###
pterodactyl:
entryPoints:
- https
rule: "Host(gpanel.DOMAIN.COM) || Host(gpanel.local.DOMAIN.COM)"
service: pterodactyl
### gpanel-node01 - router ###
gpanel-node01:
entryPoints:
- https
rule: "Host(gpanel-node01.DOMAIN.COM) || Host(gpanel-node01.local.DOMAIN.COM)"
service: gpanel-node01
services:
# pterodactyl - service
pterodactyl:
loadBalancer:
servers:
- url: http://192.168.x.x:8180
# gpanel-node01 - service
gpanel-node01:
loadBalancer:
servers:
- url: http://192.168.x.x:8181
Visit the cloudflare DNS records and use the following setup
A traefik YOUR_PUBLIC_IP Proxied Auto
CNAME Records (pointing to Traefik domain):
CNAME gpanel traefik.DOMAIN.COM Proxied Auto
CNAME gpanel-node01 traefik.DOMAIN.COM Proxied Auto