Install Guide for Evennia Codebase

This guide provides instructions for installing the Evennia codebase for first time use with our Third Generation hosting packages.  While Evennia is supported for any of our game packages, please note that Evennia's resource requirements are greater than traditional codebases and require a minimum of 100 MB of system memory for operation.  The codebase's system memory requirement will also quickly increase as your database and player base expand and may require additional resources to accommodate growth in the future.

As of this guide's writing, Evennia requires Python 3.7 and provides an installer for all required Python libs.  Using the installation guide below, you will first setup a Python version manager for the compatible Python version followed by a Software Collection environment for GCC 4.9 and a Python virtual environment configuration that is able to support the Evennia software environment independently.  The correct setup for game ports utilizing your account's registered port assignment found in your Account Welcome Email is also important to ensure that others hosted on the same server platform may setup co-existing installs without conflict.

Resources

Evennia Game Documentation: https://github.com/evennia/evennia/wiki
Evennia Install Documentation: https://github.com/evennia/evennia/wiki/Getting-Started
ASDF Version Manager: https://github.com/asdf-vm/asdf

Installation

Login to your shell account via SSH and type the following commands:

1. git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.7.8
2. echo -e '\n### ASDF Version Manager and Evennia Environment Variables' >> ~/.bash_profile
3. echo -e 'export PATH=/opt/sqlite/sqlite3.30.1/bin:$PATH' >> ~/.bash_profile
4. echo -e 'export LD_LIBRARY_PATH=/opt/sqlite/sqlite3.30.1/lib:$LD_LIBRARY_PATH' >> ~/.bash_profile
5. echo -e 'export LD_RUN_PATH=/opt/sqlite/sqlite3.30.1/lib:$LD_RUN_PATH' >> ~/.bash_profile
6. echo -e 'export TMPDIR=$HOME/tmp' >> ~/.bash_profile
7. echo -e '. $HOME/.asdf/asdf.sh' >> ~/.bash_profile
8. echo -e '. $HOME/.asdf/completions/asdf.bash' >> ~/.bash_profile
9. source ~/.bash_profile
10. asdf update
11. asdf plugin-add python
12. asdf install python 3.7.7
13. asdf global python 3.7.7
14. scl enable devtoolset-3 bash
15. python -m venv pyenv_evennia
16. source pyenv_evennia/bin/activate
17. echo "source /opt/rh/devtoolset-3/enable" >> ~/.bash_profile
18. echo "source ~/pyenv_evennia/bin/activate" >> ~/.bash_profile
19. git clone https://github.com/evennia/evennia.git
20. pip install --upgrade pip setuptools wheel
21. pip install -e evennia
22. evennia --init mygame

Configuration

Edit your game's settings file and adjust the port numbers for your account's registered port range found in your Welcome Email.

1. nano mygame/server/conf/settings.py
2. Add the following lines to the bottom of the file, adjust for your port range.

######################################################################
# Custom Settings
######################################################################
SERVERNAME = "Your Game Name Here"
TELNET_PORTS = [2000]
WEBSERVER_PORTS = [(2020, 2011)]
WEBSOCKET_CLIENT_PORT = 2010
AMP_PORT = 2012

Optional: Steps 4 through 8 - SSH and SSL configuration - install OpenSSL and add configuration to bottom of settings file if required.

4. export TMPDIR=~/tmp
5. pip install pyopenssl crypto pycrypto service_identity
6. openssl req -newkey rsa:2048 -x509 -nodes -keyout ~/mygame/server/ssl.key -out ~/mygame/server/ssl.cert -days 7300
7. nano mygame/server/conf/settings.py
8. Add the following lines to the bottom of the file, adjust for your port range.


######################################################################
# Custom SSH/SSL Settings
######################################################################
SSH_ENABLED = True
SSH_PORTS = [2001]
SSL_ENABLED = True
SSL_PORTS = [2021]

Final Codebase Setup and Startup

1. cd ~/mygame
2. evennia migrate
3. evennia start
4. When prompted, setup your Superuser account and password.

Once you have setup your account, your game's database should initialize and start successfully.

Your game should now be accessible through the telnet and HTTP web ports registered by your game's configuration.

Example: telnet yourdomainname.com 2000
Example: http://yourdomainname.com:2020

  • 7 Users Found This Useful
Was this answer helpful?

Related Articles

How to terminate a running process

This article describes how to terminate a running or non-responsive process under your shell...

Where can I find a codebase for my MUD or MUSH?

There are several freely distributed and open-source projects available that provide stable...

How to configure the Screen application

How to configure and run the application Screen in your shell account.Note: This environment...

Install Guide for PennMUSH Codebase

Description   This guide provides instructions for installing and configuring the latest...

Install Guide for TinyMUX Codebase

Description   This guide provides instructions for installing and configuring the latest...