/
example.settings.yaml
91 lines (91 loc) · 5.86 KB
/
example.settings.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# Make a copy of this file named settings.yaml and edit the copy.
# (Optional) One of DEBUG, INFO, WARNING, ERROR, or CRITICAL (values are in increasing order of severity).
log_level: WARNING
# (Optional) A URL path prefix for all endpoints. Default is "".
app_root_prefix: ""
# (Optional) This is a path to a CA certificate file used to authenticate Gameboard and Topomojo. Default is null, which makes the application trust the system's default CA certificates instead.
ca_cert_path: /usr/local/share/ca-certificates/foundry-appliance-root-ca.crt
# This is a key that will be shared with Gameboard API so that it can deploy and undeploy Cubespace games. Also used to call test endpoints.
gamebrain_admin_api_key: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
# This is a section that has various subkeys related to interactions with Identity server.
identity:
# Used to communicate with Identity.
base_url: https://foundry.local/identity
# Used to validate received tokens.
jwks_endpoint: .well-known/openid-configuration/jwks
# Configuration section for JWT **scopes** for API endpoints. The name is a holdover from early development.
jwt_audiences:
# This scope is required for an individual player's identity token.
gamebrain_api_unpriv: gamebrain-api-unpriv
# This scope is required for any interactions with the game logic API. This should be included in the Cubespace server's authentication token.
gamestate_api: gamestate-api
# Usually will be the same as base_url, but not necessarily. Check other tokens from Identity to verify the issuer.
jwt_issuer: https://foundry.local/identity
# This is a section with keys related to interactions with Topomojo.
topomojo:
# This will usually be a URL to Topomojo ending in `/api` or `/api/`.
base_api_url: https://foundry.local/topomojo/api/
# Generate a secret for the created bot account and insert it here.
x_api_key: hjQC_zO2tijlbjPnjIy258fW3J8E3Gc5
# Gamebrain will need a configured bot account in Topomojo with Observer permission enabled in order to do its work. The name of that bot account should be inserted here.
x_api_client: Administrator
# This is a section with keys related to interactions with Gameboard.
gameboard:
# Gameboard's API URL. This will usually, but not necessarily, start with `base_url` and then end with `/api` or `/api/`.
base_api_url: https://foundry.local/gameboard/api/
# Generate a secret for the created bot account and insert it here.
x_api_key: hjQC_zO2tijlbjPnjIy258fW3J8E3Gc5
# Gamebrain will need a configured bot account in Topomojo with Observer permission enabled in order to do its work. The name of that bot account should be inserted here.
x_api_client: Administrator
# This section contains database-related configuration.
db:
# This option is directly passed to create_async_engine (https://docs.sqlalchemy.org/en/20/orm/extensions/asyncio.html#sqlalchemy.ext.asyncio.create_async_engine). By default, `requirements.txt` only includes the `asyncpg` package, and that is the only one that has been tested. It should be possible to swap the async engine to use another database by installing another async package, but it has never been tested.
connection_string: postgresql+asyncpg://gamebrain:gamebrain@127.0.0.1:5432/gamebrain
# (Optional) Mostly used for testing. This will drop all tables associated with Gamebrain on startup. Defaults to false.
drop_app_tables: true
# (Optional) Mostly used for testing. Print out all SQL commands executed. Defaults to false.
echo_sql: false
# These settings set certain game parameters that are not set within the game initial state file.
game:
# (Required for PC4) This is the main grading VM. This VM will have some scripting that allows it to report completed codexes.
grading_vm_name: "challenge-server"
# (Required for PC4) This is the command that will periodically run on the above grading VM. The command should print the following keys in JSON format (values can be "success" or "fail" for the first six listed keys, "up" or "down" for the remainder):
# ```
# {
# exoArch: fail,
# redRaider: success,
# ancientRuins: fail,
# xenoCult: fail,
# museum: fail,
# finalGoal: fail,
# comms: up,
# flight: up,
# nav: down,
# pilot: up
# }
# ```
grading_vm_dispatch_command: "cat /home/user/challengeServer/custom_scripts/requestGrade.py"
# (Required for PC4) A list of dictionaries with the following keys:
challenge_tasks:
# Task ID that corresponds to a task in the JSON game data which needs to be completed within the team's gamespace.
- task_id: "redradr6"
# A VM to run a command on. This VM should not be accessible to players.
vm_name: "pirate-attacker"
# A command to execute on the target VM. The result of the command should include the string "success" or "fail".
dispatch_command: "cat /home/user/LanguageFile"
- task_id: "exoarch6"
vm_name: "station-scada-system"
dispatch_command: "cat /home/user/atmosphere"
- task_id: "cllctn6"
vm_name: "museum-approach"
dispatch_command: bash -c "cat /home/user/audit && rm /home/user/audit"
# (Required for PC4) The location ID of the "win" location, as it is specified within the game initial state JSON.
final_destination_name: "final"
# (Required for PC4) The name of a file to create on the **grading VM** to make it aware that the final goal is complete within the game.
final_destination_file_path: "/home/user/challengeServer/custom_scripts/final_goal"
# `key: value` pairs addressing each cubespace headless server. The key is the `hostname` the server program can see within its environment. The value is a public URL to the server.
headless_client_urls:
"server-1": "https://foundry.local/gameserver/1"
"server-2": "https://foundry.local/gameserver/2"
# (Optional) Whether to turn performance profiling on or not. Mostly used for development purposes. Default is false.
profiling: false