Skip to content

Commit fc409b1

Browse files
committed
Merge branch 'olivatooo-docker'
2 parents 5a2f520 + f30e220 commit fc409b1

File tree

3 files changed

+116
-11
lines changed

3 files changed

+116
-11
lines changed
Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
---
2+
title: Docker Installation
3+
description: How to use Docker to setup a nanos world server
4+
sidebar_position: 5
5+
tags: [hosting]
6+
---
7+
8+
How to use Docker to setup a nanos world server.
9+
10+
11+
:::caution Community Resource
12+
13+
The Docker setup is maintained by the community. For more details, visit the open source GitHub repository: [nanos-world-server Docker](https://github.com/olivatooo/nanos-world-server).
14+
15+
:::
16+
17+
18+
You can run nanos world server in a containerized environment using [Docker](https://www.docker.com/). This method works on any system that supports Docker (Linux, Windows, macOS).
19+
20+
## Prerequisites
21+
22+
* Docker (version 20.10 or higher)
23+
* Docker Compose (version 2.0 or higher)
24+
* At least 100MB of free disk space
25+
26+
## Quick Start with Docker Compose
27+
28+
#### 1. Create a `docker-compose.yml` file:
29+
30+
```yaml
31+
services:
32+
nanos-world-server:
33+
image: olivatooo/nanos-world-server:latest
34+
restart: unless-stopped
35+
# Uncomment to always have the latest version
36+
# pull_policy: always
37+
ports:
38+
- "7777:7777/udp"
39+
- "7777:7777/tcp"
40+
volumes:
41+
- ./Packages:/app/Packages
42+
- ./Assets:/app/Assets
43+
# Uncomment and modify to pass parameters to the server
44+
# command: ["--port", "7777", "--map", "MyMap"]
45+
```
46+
47+
#### 2. Start the server:
48+
49+
```shell
50+
docker-compose up -d
51+
```
52+
53+
#### 3. View logs:
54+
55+
```shell
56+
docker-compose logs -f
57+
```
58+
59+
#### 4. Stop the server:
60+
61+
```shell
62+
docker-compose down
63+
```
64+
65+
## Using Docker CLI
66+
67+
Alternatively, you can run the server directly with Docker:
68+
69+
```shell
70+
docker run olivatooo/nanos-world-server
71+
```
72+
73+
## Configuration
74+
75+
You can pass server parameters by modifying the `command` section in `docker-compose.yml`:
76+
77+
```yaml
78+
command: ["--max-players", "32", "--announce"]
79+
```
80+
81+
## Persistent Data
82+
83+
The Docker configuration mounts a volume to `/app` inside the container. This allows you to:
84+
- Persist server configuration files
85+
- Add custom packages and assets
86+
- Access server logs
87+
- Maintain saved data between container restarts
88+
89+
## Updating the Server
90+
91+
To update to the latest version:
92+
93+
```shell
94+
docker-compose pull
95+
docker-compose up -d
96+
```

docs/core-concepts/server-manual/server-installation.mdx

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,12 @@ The Windows server needs the latest [**Microsoft Visual C++ Redistributable**](h
2929

3030
:::
3131

32-
On Windows, you have **three** options for downloading nanos world server:
32+
On **Windows**, you have *four* options for downloading nanos world server:
3333

34-
1. Use the executable (*.exe*) already located at `nanos-world/Server/NanosWorldServer.exe` (if you downloaded the base game).
35-
2. Or download **nanos world™ Dedicated Server** tool from Steam Client.
36-
3. Use [SteamCMD](#downloading-using-steamcmd).
34+
1. Use the executable (*.exe*) already located at the game's folder `nanos-world/Server/NanosWorldServer.exe` (recommended).
35+
2. Download `nanos world™ Dedicated Server` tool from Steam Client.
36+
3. Download through [SteamCMD](#downloading-with-steamcmd).
37+
4. Using [Docker](server-docker) (maintained by the community).
3738

3839

3940
## Linux
@@ -48,11 +49,21 @@ The following Distros are granted to be supported out of the box:
4849
- `Ubuntu 22.04`
4950
- `Debian 12`
5051

51-
You can see a community created page with instructions on how to install the server on other distros and versions [here](server-linux-arm).
52+
You can see a community created page with instructions on how to install the server on other distros and versions [here](server-linux-arm). Alternatively, for other distributions or an easier setup, consider using the community maintained [**Docker**](server-docker), which handles all dependencies automatically.
5253

5354
:::
5455

55-
On Linux, the only way to download the server is through [SteamCMD](https://developer.valvesoftware.com/wiki/SteamCMD#Downloading_SteamCMD). If you are on Ubuntu/Debian, you can easily install SteamCMD like that:
56+
On **Linux**, you have *two* options for downloading nanos world server:
57+
58+
1. Download through [SteamCMD](#installing-steamcmd-on-linux) (officially supported).
59+
2. Using [Docker](server-docker) (maintained by the community).
60+
61+
**Note**: on Linux, you must start the server using the Shell Script `./NanosWorldServer.sh`, which will configure proper paths and needed dynamic libraries which need to be loaded!
62+
63+
64+
### Installing SteamCMD on Linux
65+
66+
If you are on Ubuntu/Debian, you can easily install **SteamCMD** like that:
5667

5768
<Tabs groupId="operating-systems"
5869
values={[
@@ -91,12 +102,10 @@ See the SteamCMD [official installation instructions](https://developer.valvesof
91102

92103
:::
93104

94-
**Note**: on Linux, you must start the server using the Shell Script `./NanosWorldServer.sh`, which will configure proper paths and needed dynamic libraries which need to be loaded!
95-
96105

97-
## Downloading Using SteamCMD
106+
## Downloading with SteamCMD
98107

99-
To download the server through SteamCMD (a command line version of Steam) please [download it](https://developer.valvesoftware.com/wiki/SteamCMD#Downloading_SteamCMD) before proceeding.
108+
To download the server through **SteamCMD** (a command line version of Steam) please [download it](https://developer.valvesoftware.com/wiki/SteamCMD#Downloading_SteamCMD) from the Steam official website before proceeding.
100109

101110
### Manual Installation
102111

docs/core-concepts/server-manual/server-linux-arm.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Linux & ARM Server installation
33
description: Special cases for some Linux os & ARM platform
4-
sidebar_position: 5
4+
sidebar_position: 6
55
tags: [hosting]
66
---
77

0 commit comments

Comments
 (0)