DylanMod
With this treasure I summon Dylan, Stand Proud You Are Seaweed, Nah I'd Win Said John the man who left it all behind
模組介紹 作者原文
\#
\!\codecov\\
is a mod database and API for downloading mods.
\## Setup guide for development
\- Copy \.env.template\ to \.env\ and modify as you see fit - If you
have access to the \python-packages\ submodule & it\'s cloned, make
sure to set \BUILD_INSTALL_EXTRAS\ to \true\. Any other value will
not work. Changing this setting will require rebuilding the environment
(e.g. with \docker-compose build\) for it to take effect. - Run
\docker-compose up\ - Run \`docker-compose exec django python
manage.py migrate\ in another terminal - Run \docker-compose exec
django python manage.py shell\` and enter the following code:
\\\`python from django.contrib.sites.models import Site
Site.objects.create(domain=\".localhost\",
name=\"\") \\\`
\\Make sure to substitute \localhost\ with what you use to connect
to the site!\\ In general, you should use \.localhost\
as the main domain to handle auth-scoping correctly (see
\SESSION_COOKIE_DOMAIN\ later on)
You will also need to navigate to the admin panel (\/djangoadmin\) and
configure a mapping from a site to a community. You can create a
superuser account with the \createsuperuser\ Django management command
(akin to how migrate was run) to gain access to the admin panel.
To connect a site to a community, you will need to:
1\. Make sure at least one Community object exists or create one (\`Risk
of Rain 2\` should be created automatically) 2. Make sure at least one
Site object exists or create one 3. Make the site object\'s \`domain
name\` attribute match what you use for connecting to your development
environment 4. Create a new Community Site object, linking the two
together
\### Test data population
There\'s a script for populating the local database with test data. You
can run it as follows:
\\\`bash docker-compose exec django python manage.py create_test_data
\\\`
\## Minio
In local development, \minio\ is used
for S3 compatible file storage. You can access it via
with \:\ credentials
\## REST API docs
The REST API swagger documentation can be viewed from \/api/docs/\.
At the current moment, the only relevant API is \/api/v1/package/\,
which lists all the active mods in the database. A specific mod can also
be fetched if necessary with the \/api/v1/package/{uuid4}/\ endpoint,
where \{uuid4}\ is replaced with the mod\'s uuid4 value.
\## Admin site
The admin site can be accessed from \/djangoadmin/\. To view the admin
site, you need an admin account.
Assuming docker is being used, the admin account can be created as
follows:
\\\` docker-compose exec django python manage.py createsuperuser
\\\`
Do note that if you\'re running on Windows, you will need to use winpty
for running that command.
\## Environment variable configuration for production
\### General variables
\- \DEBUG\: Should be either set to false or not at all for
production - \SECRET_KEY\: A long and random string, used to hash
passwords and other data. Should remain secret, as is implied by the
name. - \ALLOWED_HOSTS\: Comma separated list of hostnames this server
can be connected with. For example \beta..io\ -
\PRIMARY_HOST\: The public name of the server, such as
\beta..io\ - \PROTOCOL\: The protocol which to use to
build URLs to the server. Either \ or \ -
\REPOSITORY_MAX_PACKAGE_SIZE_MB\: The maximum single package size -
\REPOSITORY_MAX_PACKAGE_TOTAL_SIZE_GB\: The maximum total file size
used by packages
\### Gunicorn
\- \GUNICORN_WORKER_COUNT\: Used to control how many workers gunicorn
will spawn - \GUNICORN_LOG_LEVEL\: Used to control gunicorn\'s logging
level
\### Django
\- \SESSION_COOKIE_DOMAIN\: If set, allows sessions to be shared
within a domain and its subdomains. For example: \.io\
For local testing, recommended values are:
\- \SESSION_COOKIE_DOMAIN\: \.local
安裝與使用 安裝:BepInEx 外掛
- 本站下載的壓縮包就是模組本體,通常是 BepInEx 外掛(解壓後得到 .dll 或外掛資料夾)。
- 建議流程:用社群模組管理器(如 r2modman)選中本遊戲後匯入該模組,管理器會自動裝好 BepInEx 前置並處理依賴。
- 手動流程:先在遊戲目錄裝好 BepInEx 載入器,再把解壓出的 .dll 或外掛資料夾放進 BepInEx/plugins/。
- 啟動遊戲,BepInEx 控制台會列印載入日誌;確認這個模組出現在日誌裡即為安裝成功。
帶「前置依賴」的模組需要一併安裝,否則不會載入。功能開關通常在遊戲內或外掛自帶的設定檔裡調整。
下面這些內容需要先安裝,否則該模組不會生效: