Config document - Lost-MSth/Arcaea-server GitHub Wiki

Configuration

The setting file can be config.py file or config folder. The server will try to import it via from config import Config.

Key Type Default value Description
HOST str 0.0.0.0 Host address or IP of the main server
PORT int 80 Port of the main server
DEPLOY_MODE str flask_multithread Deployment method, including "waitress", "gevent", "flask_multithread"
USE_PROXY_FIX bool False Whether to use the proxy fix
USE_CORS bool False Whether to use the Flask-CORS
SONG_FILE_HASH_PRE_CALCULATE bool True Whether to enable song file hash pre-calcuation
GAME_API_PREFIX str | list[str] /desks/28 Game API's URL prefix If multiple are provided, they will all be enabled.
OLD_GAME_API_PREFIX list[str] [] Old game API's URL prefixes, used to send update reminders to users
ALLOW_APPVERSION list[str] [] Allowed game version If it is blank, all are allowed.
SET_LINKPLAY_SERVER_AS_SUB_PROCESS bool True Whether to run the linkplay server with the main server locally at the same time
LINKPLAY_HOST str 0.0.0.0 The address of the linkplay server based on the main server If it is blank, the link play feature will be disabled.
LINKPLAY_UDP_PORT int 10900 UDP port of the linkplay server for the client
LINKPLAY_TCP_PORT int 10901 TCP port of the linkplay server for the main server
LINKPLAY_AUTHENTICATION str my_link_play_server Authentication for the main server
LINKPLAY_DISPLAY_HOST str The address of the linkplay server based on the client If it is blank, the host of link play server for the client will be obtained automatically.
LINKPLAY_TCP_SECRET_KEY str 1145141919810 AES key of TCP communication between the main server and the linkplay server (only the first 16 chars)
SSL_CERT str File path of the SSL cert If left blank, use HTTP.
SSL_KEY str File path of the SSL cert key
IS_APRILFOOLS bool True Switch of April Fool's Day
WORLD_RANK_MAX int 200 The largest number of global rank
AVAILABLE_MAP list[str] [] Current available event maps in world mode
USERNAME str admin Username of web background management page
PASSWORD str admin Password of web background management page
SECRET_KEY str 1145141919810 Session key of web background management page
API_TOKEN str API interface full control permission token If you don't want to use it, leave it blank.
DOWNLOAD_LINK_PREFIX str Song download address prefix If left blank, it will be obtained automatically. Example: http(s)://host(:port)/download/
BUNDLE_DOWNLOAD_LINK_PREFIX str Content bundle download address prefix If left blank, it will be obtained automatically. Example: http(s)://host(:port)/download/
DOWNLOAD_USE_NGINX_X_ACCEL_REDIRECT bool False Whether to use nginx X-Accel-Redirect If true, the download contents will be blank.
NGINX_X_ACCEL_REDIRECT_PREFIX str /nginx_download/ Prefix path of X-Accel-Redirect
DOWNLOAD_TIMES_LIMIT int 3000 Player's song download limit times in 24 hours, once per file
DOWNLOAD_TIME_GAP_LIMIT int 1000 Effective duration of song download link, unit: seconds
DOWNLOAD_FORBID_WHEN_NO_ITEM bool False Make that users cannot download the songs' files if they has not bought them when the songlist file exists
BUNDLE_DOWNLOAD_TIMES_LIMIT str 100/60 minutes Player's content bundle download limit rate, once per file
BUNDLE_DOWNLOAD_TIME_GAP_LIMIT int 3000 Effective duration of content bundle download link, unit: seconds
LOGIN_DEVICE_NUMBER_LIMIT int 1 The maximum number of devices allowed to log in Arcaea, minimum: 1
ALLOW_LOGIN_SAME_DEVICE bool False Whether logging in from multiple applications on the same device is allowed Note that when this option is set to True, the next option automatically becomes False.
ALLOW_BAN_MULTIDEVICE_USER_AUTO bool True When the number of login devices exceeds the maximum number of devices allowed to log in Arcaea within 24 hours, whether the account will be automatically banned (1 day, 3 days, 7 days, 15 days, 31 days)
ALLOW_SCORE_WITH_NO_SONG bool True Whether the server accepts the score while the song is unranked(no data or negative chart const in the database)
ALLOW_INFO_LOG bool False Whether to record detailed server info logs
ALLOW_WARNING_LOG bool False Whether to record detailed server warning logs, including some custom exceptions
DEFAULT_MEMORIES int 0 The default amount of memories at the time of user registration
UPDATE_WITH_NEW_CHARACTER_DATA bool True Whether using the latest character data when updating database If you want to only keep newest official character data, please set it True. Note: If True, the old data will be lost; If False, the data changes of some characters will not be synchronized.
CHARACTER_FULL_UNLOCK bool True Whether to unlock all partners
WORLD_SONG_FULL_UNLOCK bool True Whether to unlock all world songs
WORLD_SCENERY_FULL_UNLOCK bool True Whether to unlock all world sceneries
SAVE_FULL_UNLOCK bool False Whether to force using full unlocked cloud save Please note that the current setting of the finale state is before the unlock of Testify.
BEST30_WEIGHT float 0.025 Weight of best 30 scores when calculating users' potential
RECENT10_WEIGHT float 0.025 Weight of recent top 10 scores when calculating users' potential
MAX_FRIEND_COUNT int 50 Maximum number of one user's friends
WORLD_MAP_FOLDER_PATH str ./database/map/ Data folder of world maps
SONG_FILE_FOLDER_PATH str ./database/songs/ Data folder of songs and charts
SONGLIST_FILE_PATH str ./database/songs/songlist Path of the songlist file
CONTENT_BUNDLE_FOLDER_PATH str ./database/bundle/ Data folder of content bundles with metadata
SQLITE_DATABASE_PATH str ./database/arcaea_database.db Path of database
SQLITE_DATABASE_BACKUP_FOLDER_PATH str ./database/backup/ Database backup folder
DATABASE_INIT_PATH str ./database/init/ Initial data folder of database
SQLITE_LOG_DATABASE_PATH str ./database/arcaea_log.db Path of the record database
SQLITE_DATABASE_DELETED_PATH str ./database/arcaea_database_deleted.db Path of the database which contains deleted data
GAME_LOGIN_RATE_LIMIT str 30/5 minutes Game login rate limit
API_LOGIN_RATE_LIMIT str 10/5 minutes API login rate limit