2024-01-20 12:25:29 +01:00
# Palworld Dedicated Server Docker
2024-01-19 14:58:51 +01:00
2024-01-19 15:20:51 +01:00




2024-01-19 14:58:51 +01:00
2024-01-22 16:21:08 +08:00
[View on Docker Hub ](https://hub.docker.com/r/thijsvanloef/palworld-server-docker )
2024-01-19 14:58:51 +01:00
2024-01-22 19:40:11 +01:00
> [!TIP]
2024-01-24 11:39:24 +01:00
> Unsure how to get started? Check out the [this guide I wrote!](https://tice.tips/containerization/palworld-server-docker/)
2024-01-20 12:25:29 +01:00
2024-01-24 11:39:24 +01:00
This is a Docker container to help you get started with hosting your own
[Palworld ](https://store.steampowered.com/app/1623730/Palworld/ ) dedicated server.
2024-01-20 12:30:33 +01:00
This Docker container has been tested and will work on both Linux (Ubuntu/Debian) and Windows 10.
2024-01-19 14:58:51 +01:00
2024-01-21 11:31:30 +01:00
> [!IMPORTANT]
> At the moment, Xbox Gamepass/Xbox Console players will not be able to join a dedicated server.
>
> They will need to join players using the invite code and are limited to sessions of 4 players max.
2024-01-19 14:58:51 +01:00
## How to use
2024-01-24 11:20:32 +01:00
Keep in mind that you'll need to change the [environment variables ](#environment-variables ).
2024-01-19 14:58:51 +01:00
### Docker Compose
This repository includes an example [docker-compose.yml ](example/docker-compose.yml ) file you can use to setup your server.
```yml
services:
palworld:
2024-01-21 20:04:45 +01:00
image: thijsvanloef/palworld-server-docker:latest
2024-01-19 14:58:51 +01:00
restart: unless-stopped
container_name: palworld-server
ports:
2024-01-19 15:07:14 +01:00
- 8211:8211/udp
- 27015:27015/udp
2024-01-19 14:58:51 +01:00
environment:
2024-01-20 22:22:30 -08:00
- PUID=1000
- PGID=1000
2024-01-21 20:04:45 +01:00
- PORT=8211 # Optional but recommended
- PLAYERS=16 # Optional but recommended
2024-01-23 20:46:30 +01:00
- MULTITHREADING=true
2024-01-22 23:08:06 +01:00
- RCON_ENABLED=true
2024-01-22 19:12:41 +01:00
- RCON_PORT=25575
2024-01-25 09:02:20 +01:00
- TZ=UTC
2024-01-22 19:12:41 +01:00
- ADMIN_PASSWORD="adminPasswordHere"
2024-01-19 18:34:41 +01:00
- COMMUNITY=false # Enable this if you want your server to show up in the community servers tab, USE WITH SERVER_PASSWORD!
2024-01-19 19:09:36 +01:00
# Enable the environment variables below if you have COMMUNITY=true
# - SERVER_PASSWORD="worldofpals"
# - SERVER_NAME="World of Pals"
2024-01-19 14:58:51 +01:00
volumes:
2024-01-21 20:04:45 +01:00
- ./palworld:/palworld/
2024-01-19 14:58:51 +01:00
```
### Docker Run
Change every < > to your own configuration
```bash
docker run -d \
--name palworld-server \
-p 8211:8211/udp \
-p 27015:27015/udp \
-v ./< palworld-folder > :/palworld/ \
2024-01-20 22:22:30 -08:00
-e PUID=1000 \
-e PGID=1000 \
2024-01-24 10:47:46 +01:00
-e PORT=8211 \
-e PLAYERS=16 \
-e MULTITHREADING=true \
-e RCON_ENABLED=true \
-e RCON_PORT=25575 \
2024-01-25 09:02:20 +01:00
-e TZ=UTC \
2024-01-24 10:47:46 +01:00
-e ADMIN_PASSWORD="adminPasswordHere" \
2024-01-19 18:34:41 +01:00
-e COMMUNITY=false \
2024-01-19 14:58:51 +01:00
--restart unless-stopped \
2024-01-24 10:47:46 +01:00
thijsvanloef/palworld-server-docker:latest
2024-01-19 14:58:51 +01:00
```
2024-01-24 11:14:56 +01:00
### Kubernetes
All files you will need to deploy this container to kubernetes are located in the [k8s folder ](k8s/ ).
Follow the steps in the [README.md here ](k8s/readme.md ) to deploy it.
2024-01-19 14:58:51 +01:00
### Environment variables
You can use the following values to change the settings of the server on boot.
It is highly recommended you set the following environment values before starting the server:
* PLAYERS
* PORT
2024-01-23 20:46:30 +01:00
* PUID
* PGID
2024-01-19 14:58:51 +01:00
2024-01-19 18:22:08 +01:00
| Variable | Info | Default Values | Allowed Values |
2024-01-22 19:12:41 +01:00
|------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------|----------------|
2024-01-24 16:20:26 -05:00
| TZ | Timezone used for time stamping backup server | UTC | See [TZ Identifiers ](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#Time_Zone_abbreviations ) |
2024-01-19 18:22:08 +01:00
| PLAYERS* | Max amount of players that are able to join the server | 16 | 1-31 |
| PORT* | UDP port that the server will expose | 8211 | 1024-65535 |
2024-01-20 23:34:37 -08:00
| PUID* | The uid of the user the server should run as | 1000 | !0 |
| PGID* | The gid of the group the server should run as | 1000 | !0 |
2024-01-19 18:22:08 +01:00
| MULTITHREADING** | Improves performance in multi-threaded CPU environments. It is effective up to a maximum of about 4 threads, and allocating more than this number of threads does not make much sense. | false | true/false |
| COMMUNITY | Whether or not the server shows up in the community server browser (USE WITH SERVER_PASSWORD) | false | true/false |
| PUBLIC_IP | You can manually specify the global IP address of the network on which the server running.If not specified, it will be detected automatically. If it does not work well, try manual configuration. | | x.x.x.x |
2024-01-24 18:28:19 +08:00
| PUBLIC_PORT | You can manually specify the port number of the network on which the server running.If not specified, it will be detected automatically. If it does not work well, try manual configuration. | | 1024-65535 |
2024-01-19 19:35:32 +01:00
| SERVER_NAME | A name for your community server | | "string" |
| SERVER_PASSWORD | Secure your community server with a password | | "string" |
2024-01-19 16:05:51 -05:00
| ADMIN_PASSWORD | Secure administration access in the server with a password | | "string" |
2024-01-19 19:39:53 +01:00
| UPDATE_ON_BOOT** | Update/Install the server when the docker container starts (THIS HAS TO BE ENABLED THE FIRST TIME YOU RUN THE CONTAINER) | true | true/false |
2024-01-22 19:12:41 +01:00
| RCON_ENABLED | Enable RCON for the Palworld server | true | true/false |
| RCON_PORT | RCON port to connect to | 25575 | 1024-65535 |
2024-01-23 21:01:23 +01:00
| QUERY_PORT | Query port used to communicate with Steam servers | 27015 | 1024-65535 |
2024-01-19 14:58:51 +01:00
*highly recommended to set
2024-01-23 00:07:51 +09:00
** Make sure you know what you are doing when running this option enabled
2024-01-19 14:58:51 +01:00
2024-01-19 15:16:00 +01:00
### Game Ports
2024-01-23 20:46:30 +01:00
| Port | Info |
|-------|------------------|
| 8211 | Game Port (UDP) |
| 27015 | Query Port (UDP) |
| 25575 | RCON Port (TCP) |
2024-01-22 19:12:41 +01:00
## Using RCON
RCON is enabled by default for the palworld-server-docker image.
2024-01-23 11:22:52 +01:00
Opening the RCON cli is quite easy:
2024-01-22 19:12:41 +01:00
```bash
2024-01-23 11:22:52 +01:00
docker exec -it palworld-server rcon-cli
2024-01-22 19:12:41 +01:00
```
2024-01-23 11:22:52 +01:00
This will open a CLI that use can use to write commands to the Palworld Server.
2024-01-22 19:12:41 +01:00
### List of server commands
2024-01-23 20:46:30 +01:00
| Command | Info |
|----------------------------------|-----------------------------------------------------|
2024-01-22 19:26:21 +01:00
| Shutdown {Seconds} {MessageText} | The server is shut down after the number of Seconds |
| DoExit | Force stop the server. |
| Broadcast | Send message to all player in the server |
2024-01-23 20:46:30 +01:00
| KickPlayer {SteamID} | Kick player from the server.. |
2024-01-22 19:26:21 +01:00
| BanPlayer {SteamID} | BAN player from the server. |
| TeleportToPlayer {SteamID} | Teleport to current location of target player. |
| TeleportToMe {SteamID} | Target player teleport to your current location |
| ShowPlayers | Show information on all connected players. |
| Info | Show server information. |
| Save | Save the world data. |
2024-01-22 19:12:41 +01:00
For a full list of commands go to: [https://tech.palworldgame.com/server-commands ](https://tech.palworldgame.com/server-commands )
2024-01-19 15:16:00 +01:00
2024-01-24 12:52:48 +01:00
## Creating a backup
2024-01-24 18:32:59 +07:00
To create a backup of the game's save at the current point in time, use the command.
```bash
2024-01-24 12:52:48 +01:00
docker exec palworld-server backup
2024-01-24 18:32:59 +07:00
```
2024-01-24 12:52:48 +01:00
This will create a backup at `/palworld/backups/`
2024-01-25 02:25:14 -05:00
## Setting Up Automatic Backups with Cron
2024-01-25 07:09:30 -05:00
Setting Up Automatic Backups with Cron
2024-01-25 02:25:14 -05:00
2024-01-25 07:09:30 -05:00
### Environment Variables
2024-01-25 02:25:14 -05:00
2024-01-25 07:09:30 -05:00
**DAYS_TO_KEEP:**
2024-01-25 02:25:14 -05:00
2024-01-25 07:09:30 -05:00
Description: This environment variable represents the number of days to retain backup files. It is used in the cleanup process to remove backup files older than the specified duration.
Example Usage: If set to 7, backup files older than 7 days will be deleted during the cleanup.
**BACKUP_CRON_EXPRESSION:**
Description: This environment variable defines the cron expression for scheduling automatic backups. It determines when the backup script should run at specific intervals.
Example Usage: If set to 0 2 * * *, the backup script will run every day at 2:00 AM.
2024-01-25 02:25:14 -05:00
2024-01-25 07:09:30 -05:00
**BACKUP_ENABLED:**
Description: This environment variable indicates whether automatic backups are enabled or not. If set to a non-empty value, automatic backups will be enabled; otherwise, they will be disabled.
Example Usage: If set to any non-empty string (e.g., true or 1), the backup script will be configured and executed as per the specified cron schedule.
Example:
2024-01-25 02:25:14 -05:00
```bash
2024-01-25 07:09:30 -05:00
DAYS_TO_KEEP=7
BACKUP_CRON_EXPRESSION="0 2 * * *"
BACKUP_ENABLED=true
2024-01-25 02:25:14 -05:00
```
2024-01-23 13:41:03 +01:00
## Editing Server Settings
2024-01-23 15:03:04 -07:00
When the server starts, a `PalWorldSettings.ini` file will be created in the following location: `<mount_folder>/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini`
2024-01-23 13:41:03 +01:00
Any changes made there will be applied to the Server on next boot.
Please keep in mind that the ENV variables will always overwrite the changes made to `PalWorldSettings.ini` .
2024-01-24 17:54:17 +01:00
For a more detailed list of explanations of server settings go to: [shockbyte ](https://shockbyte.com/billing/knowledgebase/1189/How-to-Configure-your-Palworld-server.html )
2024-01-23 13:41:03 +01:00
> [!TIP]
2024-01-24 11:39:24 +01:00
> If the `<mount_folder>/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini` is empty,
> delete the file and restart the server, a new file with content will be created.
2024-01-23 13:41:03 +01:00
2024-01-19 14:58:51 +01:00
## Reporting Issues/Feature Requests
Issues/Feature requests can be submitted by using [this link ](https://github.com/thijsvanloef/palworld-server-docker/issues/new/choose ).
2024-01-20 15:17:04 +01:00
### Known Issues
2024-01-20 22:22:30 -08:00
Known issues are listed in the [wiki ](https://github.com/thijsvanloef/palworld-server-docker/wiki/Known-Issues )