[[ OoC: I am assuming that you have followed this guide and have already managed to launch an ordinary Dedicated Server. One that has both overworld and caves.
To make a server Caves Only….
Start with fresh files. That means deleting the backup and server logs from your Master server folder ( Klei/DoNotStarveTogether/MyDediServer ).
Next: delete the caves folder [ Klei/DoNotStarveTogether/MyDediServer/Caves ]. Each folder, the caves and the Master, is a server. We are going to delete the caves folder, make it so there is only one server (the master) and make that one server a caves map.
Go and open your StarDSTServers in an editing program ( I use Notepad ++ because it is free and convenient).
Remove the string that makes a “-shard caves”. This will make it so the StartDSTServers only makes one server, a surface world, as opposed to surface and caves. Next we are going to edit that one server so that it generates as a caves map instead of a surface map.
To edit that server go to Klei/DoNotStarveTogether/MyDediServer/Master
Once in the folder create a new TEXT file called “worldgenoverride.lua”. You can do this with Notepad or Notepad ++.
[The above screenshot has my backup, chat logs, and save files. Ideally you shouldnt have this yet since you are starting a new server]
Inside that new worldgenoverride.lua file paste the following
then save and exit the file. This file will make it so that whichever server it is inside will generate as a caves map. Since we have only one server (the Master) and since it has this file, it will generate as a Caves map. Since there is no second server to connect to the staircases in the game will be plugged.
Go back to StarDSTServers and try booting up! If all is well the server will generate as a caves only server. Congratulations! You just figured out how to condemn Wilson to a underground labyrinth of insanity and death!
What this basically does is:
1: Make it so there is only one dedicated server generating (the master server with no caves server attached)
2: add the worldgenoverride.lua to turn that master server into a caves only server.
I wish you luck brave spelunker! Wilson is going to need it!