Difference between revisions of "Server Setup"
From #openttdcoop wiki
m (moved Server Administration New to Server Setup: Title better fits the content of the page) |
m (→CoopServer (Soap): Link to config.py) |
||
(16 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | == | + | == Server details == |
{| class="wikitable" | {| class="wikitable" | ||
|+ publicserver-new.openttdcoop.org | |+ publicserver-new.openttdcoop.org | ||
− | |- | + | |- align="center" |
! Name !! Address !! Port !! Admin Port !! IRC channel !! Directory | ! Name !! Address !! Port !! Admin Port !! IRC channel !! Directory | ||
− | |- | + | |- align="center" |
− | + | | Public Server || publicserver-new.openttdcoop.org || 3979 (3983) || 4079 (3980) || #openttdcoop || ~/svn-publicserver/ | |
|} | |} | ||
{| class="wikitable" | {| class="wikitable" | ||
|+ games.openttdcoop.org | |+ games.openttdcoop.org | ||
− | |- | + | |- align="center" |
! Name !! Address !! Port !! Admin Port !! IRC channel !! Directory | ! Name !! Address !! Port !! Admin Port !! IRC channel !! Directory | ||
− | |- | + | |- align="center" |
− | + | | Nightly || nightly.openttdcoop.org || 3997 || 3996 || #openttdcoop.nightly || ~/svn-nightly/ | |
+ | |- align="center" | ||
+ | | ProZone || pz.openttdcoop.org || 3982 || 3981 || #openttdcoop.pro || ~/svn-prozone/ | ||
+ | |- align="center" | ||
+ | | Welcome Server || stable.openttdcoop.org || 3999 || 3998 || #openttdcoop.stable || ~/svn-stable/ | ||
|} | |} | ||
− | + | Permanent servers should have unique game- and adminports assigned to them. | |
− | + | Temporary servers should all share the same ports, and also the same irc-channel. This makes it easier to switch CoopServer between them. | |
+ | Portnumbers in () are temporary, and will be removed once the ports are updated | ||
== Directory Structure == | == Directory Structure == | ||
Each server should adhere to the following directory structure: | Each server should adhere to the following directory structure: | ||
− | |||
===Top directory=== | ===Top directory=== | ||
Contains the SVN checkout, existing files should not be altered manually. The subdirectories bin/, bundle/, media/, os/, projects/ and src/ are also part of the SVN checkout and should not be altered manually. | Contains the SVN checkout, existing files should not be altered manually. The subdirectories bin/, bundle/, media/, os/, projects/ and src/ are also part of the SVN checkout and should not be altered manually. | ||
− | |||
===Patches/ (NOT YET IMPLEMENTED)=== | ===Patches/ (NOT YET IMPLEMENTED)=== | ||
− | Contains patches to applied to the source. Unless the server is meant to test patches for multi-player compatibility, patches in here should be multi-player safe. No changes in savegame allowed either, we want people to be able to download and play these games in vanilla OpenTTD | + | Contains patches to applied to the source. Unless the server is meant to test patches for multi-player compatibility, patches in here should be multi-player safe. No changes in savegame allowed either, we want people to be able to download and play these games in vanilla OpenTTD. |
− | + | ||
===Server/=== | ===Server/=== | ||
In here is the actual running server. important files include: | In here is the actual running server. important files include: | ||
Line 32: | Line 34: | ||
* openttd: The game, need I say more? Preferably use ofs-start.py to start it rather than simply running ./openttd. Ofs-start will ensure the right cfg file and latest autosave gets loaded | * openttd: The game, need I say more? Preferably use ofs-start.py to start it rather than simply running ./openttd. Ofs-start will ensure the right cfg file and latest autosave gets loaded | ||
* openttd.cfg: Server configuration file | * openttd.cfg: Server configuration file | ||
− | * openttd.log: As OpenTTD now gets started with -D -f and no longer within a screen session, the console output gets logged into this file. | + | * openttd.log: As OpenTTD now gets started with -D -f and no longer within a screen session, the console output gets logged into this file. use 'tail -f openttd.log' if you need a live feed of console output |
* openttd.pid: Used by ofs-start to determine wether openttd is already running or not. Contains the pid from the last time ofs-start started the server | * openttd.pid: Used by ofs-start to determine wether openttd is already running or not. Contains the pid from the last time ofs-start started the server | ||
* save/autosave/: Ofs-start will load the most recent savegame from here, including autosavesoap.sav (generated when Soap shuts down the server for restart/update etc.) | * save/autosave/: Ofs-start will load the most recent savegame from here, including autosavesoap.sav (generated when Soap shuts down the server for restart/update etc.) | ||
* save/uploads/: Set ofs-getsave to download savegames into this directory. | * save/uploads/: Set ofs-getsave to download savegames into this directory. | ||
− | |||
===Web/=== | ===Web/=== | ||
− | This directory willbe accessible through http as http://<serveraddress>/<port>/. Ofs-scripts will place some files here needed by tools such as | + | This directory willbe accessible through http as http://<serveraddress>/<port>/. Ofs-scripts will place some files here needed by tools such as Zuu's Ottdau. |
− | * | + | * finger/openttd: Contains a line similar to the ones in openttd.org's finger.txt, with the branch and revision used. |
− | + | ||
− | + | ||
== Required extras == | == Required extras == | ||
===Openttd File Scripts (OFS, http://dev.openttdcoop.org/projects/ofs)=== | ===Openttd File Scripts (OFS, http://dev.openttdcoop.org/projects/ofs)=== | ||
These file scripts should be installed in the server/ directory, where the server binary is located. Configure these for the above directory structure by editing the appropriate scripts. Each one contains a few configuration lines at the top of the file. For more information see the included README.txt | These file scripts should be installed in the server/ directory, where the server binary is located. Configure these for the above directory structure by editing the appropriate scripts. Each one contains a few configuration lines at the top of the file. For more information see the included README.txt | ||
+ | |||
+ | |||
+ | == CoopServer (Soap) == | ||
+ | A bot-owner has to add the server to the CoopServer irc-bot. | ||
+ | # Make CoopServer join the channel using '!join #channel' | ||
+ | # Use '!config channel plugins.Soap.<variable> <value>' from within the channel to set up the various settings. See Soap's config.py (available online at https://rhodecode.openttdcoop.org/soap/files/tip/config.py) for a description of what each one does. The defaults make sense. Make sure that you do not set the adminport password in the channel!! For that use '!config channel <channel> plugins.Soap.password <password>' in a private message to the bot. | ||
+ | # Last but not least, the channel will need to be added to plugins.Soap.channels. First use '!config plugins.Soap.channels' without any value to get the current one. run the same command again, this time adding the existing channellist as well as the channel to be added: '!config plugins.Soap.channels #openttdcoop #openttdcoop.stable'. | ||
+ | # use '!reload Soap' to reload the plugin so that it will read the new server configuration. Warning: will cause all existing servers to momentarily lose connection. Those with autoConnect=True will automatically reconnect though. | ||
+ | # Test it. use '!start' and '!apconnect' to check that everything works as you expect it to work. | ||
+ | |||
[[Category:Guides]] | [[Category:Guides]] |
Latest revision as of 20:58, 10 March 2014
Contents
Server details
Name | Address | Port | Admin Port | IRC channel | Directory |
---|---|---|---|---|---|
Public Server | publicserver-new.openttdcoop.org | 3979 (3983) | 4079 (3980) | #openttdcoop | ~/svn-publicserver/ |
Name | Address | Port | Admin Port | IRC channel | Directory |
---|---|---|---|---|---|
Nightly | nightly.openttdcoop.org | 3997 | 3996 | #openttdcoop.nightly | ~/svn-nightly/ |
ProZone | pz.openttdcoop.org | 3982 | 3981 | #openttdcoop.pro | ~/svn-prozone/ |
Welcome Server | stable.openttdcoop.org | 3999 | 3998 | #openttdcoop.stable | ~/svn-stable/ |
Permanent servers should have unique game- and adminports assigned to them. Temporary servers should all share the same ports, and also the same irc-channel. This makes it easier to switch CoopServer between them. Portnumbers in () are temporary, and will be removed once the ports are updated
Directory Structure
Each server should adhere to the following directory structure:
Top directory
Contains the SVN checkout, existing files should not be altered manually. The subdirectories bin/, bundle/, media/, os/, projects/ and src/ are also part of the SVN checkout and should not be altered manually.
Patches/ (NOT YET IMPLEMENTED)
Contains patches to applied to the source. Unless the server is meant to test patches for multi-player compatibility, patches in here should be multi-player safe. No changes in savegame allowed either, we want people to be able to download and play these games in vanilla OpenTTD.
Server/
In here is the actual running server. important files include:
- content_download: This should sym-link to shared content_download per user, generally ~/content_download/
- ofs-*: Filehandling scripts used by Soap. These can be executed manually for troubleshooting.
- openttd: The game, need I say more? Preferably use ofs-start.py to start it rather than simply running ./openttd. Ofs-start will ensure the right cfg file and latest autosave gets loaded
- openttd.cfg: Server configuration file
- openttd.log: As OpenTTD now gets started with -D -f and no longer within a screen session, the console output gets logged into this file. use 'tail -f openttd.log' if you need a live feed of console output
- openttd.pid: Used by ofs-start to determine wether openttd is already running or not. Contains the pid from the last time ofs-start started the server
- save/autosave/: Ofs-start will load the most recent savegame from here, including autosavesoap.sav (generated when Soap shuts down the server for restart/update etc.)
- save/uploads/: Set ofs-getsave to download savegames into this directory.
Web/
This directory willbe accessible through http as http://<serveraddress>/<port>/. Ofs-scripts will place some files here needed by tools such as Zuu's Ottdau.
- finger/openttd: Contains a line similar to the ones in openttd.org's finger.txt, with the branch and revision used.
Required extras
Openttd File Scripts (OFS, http://dev.openttdcoop.org/projects/ofs)
These file scripts should be installed in the server/ directory, where the server binary is located. Configure these for the above directory structure by editing the appropriate scripts. Each one contains a few configuration lines at the top of the file. For more information see the included README.txt
CoopServer (Soap)
A bot-owner has to add the server to the CoopServer irc-bot.
- Make CoopServer join the channel using '!join #channel'
- Use '!config channel plugins.Soap.<variable> <value>' from within the channel to set up the various settings. See Soap's config.py (available online at https://rhodecode.openttdcoop.org/soap/files/tip/config.py) for a description of what each one does. The defaults make sense. Make sure that you do not set the adminport password in the channel!! For that use '!config channel <channel> plugins.Soap.password <password>' in a private message to the bot.
- Last but not least, the channel will need to be added to plugins.Soap.channels. First use '!config plugins.Soap.channels' without any value to get the current one. run the same command again, this time adding the existing channellist as well as the channel to be added: '!config plugins.Soap.channels #openttdcoop #openttdcoop.stable'.
- use '!reload Soap' to reload the plugin so that it will read the new server configuration. Warning: will cause all existing servers to momentarily lose connection. Those with autoConnect=True will automatically reconnect though.
- Test it. use '!start' and '!apconnect' to check that everything works as you expect it to work.