Skip to content

Commit

Permalink
Create environment variable for default language (#648)
Browse files Browse the repository at this point in the history
* Create environment variable for default language

* Update wis2box-create-config.py
  • Loading branch information
webb-ben authored Apr 23, 2024
1 parent 9a4e0fc commit 764f355
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/source/reference/configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ Web application configuration provides the ability to customize web components.
WIS2BOX_BASEMAP_URL="https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png" # URL of map tile server to use
WIS2BOX_BASEMAP_ATTRIBUTION="<a href="https://osm.org/copyright">OpenStreetMap</a> contributors" # attribution of map tile server
WIS2BOX_UI_CLUSTER=False # default setting of the cluster toggle
WIS2BOX_UI_LANG="en" # default language, one of: ar, en, es, fr, ru, zh
Other
^^^^^
Expand Down
1 change: 1 addition & 0 deletions tests/test.env
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ WIS2BOX_DATADIR=/data/wis2box
# wis2box public URL
WIS2BOX_URL=http://localhost
WIS2BOX_UI_CLUSTER=false
WIS2BOX_UI_LANG=en

# api
WIS2BOX_API_TYPE=pygeoapi
Expand Down
1 change: 1 addition & 0 deletions wis2box-create-config.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,7 @@ def create_wis2box_env(config_dir: str) -> None:
fh.write('# wis2box public URL\n')
fh.write(f'WIS2BOX_URL={wis2box_url}\n')
fh.write('WIS2BOX_UI_CLUSTER=false\n')
fh.write('WIS2BOX_UI_LANG=en\n')
fh.write('\n')
fh.write('# api\n')
fh.write('WIS2BOX_API_TYPE=pygeoapi\n')
Expand Down

0 comments on commit 764f355

Please sign in to comment.