mirror of
https://github.com/YuzuZensai/palworld-server-docker.git
synced 2026-01-30 12:22:57 +00:00
Merge pull request #34 from thijsvanloef/move-port-and-players
make port and players optional
This commit is contained in:
@@ -7,10 +7,10 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||||||
&& apt-get clean \
|
&& apt-get clean \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
ENV PORT=8211 \
|
ENV PORT= \
|
||||||
PUID=1000 \
|
PUID=1000 \
|
||||||
PGID=1000 \
|
PGID=1000 \
|
||||||
PLAYERS=16 \
|
PLAYERS= \
|
||||||
MULTITHREADING=false \
|
MULTITHREADING=false \
|
||||||
COMMUNITY=false \
|
COMMUNITY=false \
|
||||||
PUBLIC_IP= \
|
PUBLIC_IP= \
|
||||||
|
|||||||
12
README.md
12
README.md
@@ -29,25 +29,25 @@ This repository includes an example [docker-compose.yml](example/docker-compose.
|
|||||||
```yml
|
```yml
|
||||||
services:
|
services:
|
||||||
palworld:
|
palworld:
|
||||||
image: thijsvanloef/palworld-server-docker
|
image: thijsvanloef/palworld-server-docker:latest
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
container_name: palworld-server
|
container_name: palworld-server
|
||||||
ports:
|
ports:
|
||||||
- 8211:8211/udp
|
- 8211:8211/udp
|
||||||
- 27015:27015/udp
|
- 27015:27015/udp
|
||||||
environment:
|
environment:
|
||||||
- PORT=8211
|
|
||||||
- PUID=1000
|
- PUID=1000
|
||||||
- PGID=1000
|
- PGID=1000
|
||||||
- PLAYERS=16
|
- PORT=8211 # Optional but recommended
|
||||||
- MULTITHREADING=FALSE
|
- PLAYERS=16 # Optional but recommended
|
||||||
|
- MULTITHREADING=false
|
||||||
- COMMUNITY=false # Enable this if you want your server to show up in the community servers tab, USE WITH SERVER_PASSWORD!
|
- COMMUNITY=false # Enable this if you want your server to show up in the community servers tab, USE WITH SERVER_PASSWORD!
|
||||||
# Enable the environment variables below if you have COMMUNITY=true
|
# Enable the environment variables below if you have COMMUNITY=true
|
||||||
# - SERVER_PASSWORD="worldofpals"
|
# - SERVER_PASSWORD="worldofpals"
|
||||||
# - SERVER_NAME="World of Pals"
|
# - SERVER_NAME="World of Pals"
|
||||||
# - ADMIN_PASSWORD="someAdminPassword"
|
# - ADMIN_PASSWORD="someAdminPassword"
|
||||||
volumes:
|
volumes:
|
||||||
- /path/to/your/palworld/folder:/palworld/
|
- ./palworld:/palworld/
|
||||||
```
|
```
|
||||||
|
|
||||||
### Docker Run
|
### Docker Run
|
||||||
@@ -77,7 +77,6 @@ It is highly recommended you set the following environment values before startin
|
|||||||
|
|
||||||
* PLAYERS
|
* PLAYERS
|
||||||
* PORT
|
* PORT
|
||||||
* MULTITHREADING
|
|
||||||
|
|
||||||
| Variable | Info | Default Values | Allowed Values |
|
| Variable | Info | Default Values | Allowed Values |
|
||||||
| ---------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------- | -------------- |
|
| ---------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------- | -------------- |
|
||||||
@@ -94,7 +93,6 @@ It is highly recommended you set the following environment values before startin
|
|||||||
| ADMIN_PASSWORD | Secure administration access in the server with a password | | "string" |
|
| ADMIN_PASSWORD | Secure administration access in the server with a password | | "string" |
|
||||||
| 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 |
|
| 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 |
|
||||||
|
|
||||||
|
|
||||||
*highly recommended to set
|
*highly recommended to set
|
||||||
|
|
||||||
** Make sure you know what you are doing when running this this option enabled
|
** Make sure you know what you are doing when running this this option enabled
|
||||||
|
|||||||
@@ -7,12 +7,11 @@ services:
|
|||||||
- 8211:8211/udp
|
- 8211:8211/udp
|
||||||
- 27015:27015/udp
|
- 27015:27015/udp
|
||||||
environment:
|
environment:
|
||||||
- PORT=8211
|
|
||||||
- PUID=1000
|
- PUID=1000
|
||||||
- PGID=1000
|
- PGID=1000
|
||||||
- PLAYERS=16
|
- PORT=8211 # Optional but recommended
|
||||||
|
- PLAYERS=16 # Optional but recommended
|
||||||
- MULTITHREADING=false
|
- MULTITHREADING=false
|
||||||
- UPDATE_ON_BOOT=true
|
|
||||||
- COMMUNITY=false # Enable this if you want your server to show up in the community servers tab, USE WITH SERVER_PASSWORD!
|
- COMMUNITY=false # Enable this if you want your server to show up in the community servers tab, USE WITH SERVER_PASSWORD!
|
||||||
# Enable the environment variables below if you have COMMUNITY=true
|
# Enable the environment variables below if you have COMMUNITY=true
|
||||||
# - SERVER_PASSWORD="worldofpals"
|
# - SERVER_PASSWORD="worldofpals"
|
||||||
|
|||||||
@@ -1,6 +1,14 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
STARTCOMMAND="./PalServer.sh -port=${PORT} -players=${PLAYERS}"
|
STARTCOMMAND="./PalServer.sh"
|
||||||
|
|
||||||
|
if [ -n "${PORT}" ]; then
|
||||||
|
STARTCOMMAND="${STARTCOMMAND} -port=${PORT}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "${PLAYERS}" ]; then
|
||||||
|
STARTCOMMAND="${STARTCOMMAND} -players=${PLAYERS}"
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "${COMMUNITY}" = true ]; then
|
if [ "${COMMUNITY}" = true ]; then
|
||||||
STARTCOMMAND="${STARTCOMMAND} EpicApp=PalServer"
|
STARTCOMMAND="${STARTCOMMAND} EpicApp=PalServer"
|
||||||
|
|||||||
Reference in New Issue
Block a user