Skip to content

config-set

Set or update a value in ritual.config.json.

Terminal window
./ritual config-set [options] <property> <value...>
ArgumentDescriptionRequired
<property>The config key to set (dot notation for nested)Yes
<value...>One or more values to setYes
OptionDescription
--addAppend value(s) to an array property (no duplicates)
--removeRemove value(s) from an array property
PropertyTypeDefault
decksDirstring./decks
collectionsDirstring./collections
wantedDirstring./wanted

The nested admin keys — settings for the admin server — are set with dot notation:

PropertyTypeDefault
admin.gitEnabledbooleanfalse
admin.gitAutoCommitbooleanfalse
admin.gitAutoPushbooleanfalse
admin.trustProxybooleanfalse
admin.secureCookiesbooleanfalse
admin.ipAllowListstring[][]
admin.ipDenyListstring[][]
admin.userAgentAllowListstring[][]
admin.userAgentDenyListstring[][]
admin.rateLimitEnabledbooleantrue
admin.rateLimitMaxAttemptsnumber5
admin.rateLimitWindowMinutesnumber5
admin.failedAuthDelayMsnumber3000

The following nested site keys — the public-site publish lists — are also settable:

PropertyTypeDefault
site.includeDecksstring[]["*"]
site.includeCollectionsstring[]["*"]
site.includeWantedListsstring[]["*"]
site.excludeDecksstring[][]
site.excludeCollectionsstring[][]
site.excludeWantedListsstring[][]
site.bannedPrintingsstring[][]

Each exclude* list drops lists by display name even when the matching include* list selects them; exclusion always wins. The exclude lists have no wildcard and default to empty. The admin Manage Lists page edits them through per-list visibility toggles.

site.bannedPrintings blocks specific printings from being chosen as a card’s default (featured) printing when no printing is otherwise specified. Each entry is a SET:COLLECTOR pair (e.g. SLD:123). Ritual normally features the most recent non-outlier printing among a card’s five newest priced printings; when that printing is banned, it skips to the next eligible one. A banned printing can still be viewed and entered manually — it is only barred from automatic selection. Set codes are stored lowercase; the value you pass may use either case.

The rest of the site key (the deployment settings) is managed exclusively by ritual init-site and cannot be set with this command.

  • string — passed as-is.
  • boolean — must be true or false (case-insensitive).
  • number — must be a non-negative integer.
  • string[] — one or more values. By default the whole array is replaced. Use --add or --remove to modify individual entries. Arrays are treated as sets; duplicate values are ignored.

Enable git integration:

Terminal window
./ritual config-set admin.gitEnabled true

Change the decks directory:

Terminal window
./ritual config-set decksDir ./my-decks

Set an IP allowlist (replaces the whole list):

Terminal window
./ritual config-set admin.ipAllowList "192.168.1.0/24" "10.0.0.1"

Add an IP to an existing allowlist:

Terminal window
./ritual config-set --add admin.ipAllowList "10.0.0.2"

Remove an IP from the allowlist:

Terminal window
./ritual config-set --remove admin.ipAllowList "10.0.0.1"

Increase the rate-limit window:

Terminal window
./ritual config-set admin.rateLimitWindowMinutes 10

Publish only specific decks on the built site (replaces the whole list):

Terminal window
./ritual config-set site.includeDecks "Izzet Storm" "Atraxa Superfriends"

Reset a publish list back to “everything”:

Terminal window
./ritual config-set site.includeCollections "*"

Hide a single deck from the built site (leaving the rest published):

Terminal window
./ritual config-set --add site.excludeDecks "Untuned Brew"

Stop a specific printing from being featured as a card’s default (it can still be selected manually):

Terminal window
./ritual config-set --add site.bannedPrintings "SLD:123"
  • Changes are written to ritual.config.json immediately.
  • Running the admin server picks up config changes on its next request; a running server does not need to be restarted.
  • Use --base-dir to target a config file in a directory other than the current working directory.