Skip to content

Commit

Permalink
feat: mods config loc
Browse files Browse the repository at this point in the history
closes #9 and #13
  • Loading branch information
Laura Demkowicz-Duffy committed Mar 10, 2022
1 parent 61c1ee7 commit 3f0dd03
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
7 changes: 5 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -77,18 +77,21 @@ RUN mkdir -p bepinexpack r2api engimaticthunder && \
FROM vanilla AS bepinex

ENV MODS_LOC="/plugins"
ENV MODS_CONFIG_LOC="/plugin_config"

USER root
RUN mkdir -p $MODS_LOC && \
chown -R ror2:ror2 $MODS_LOC
RUN mkdir -p $MODS_LOC $MODS_CONFIG_LOC && \
chown -R ror2:ror2 $MODS_LOC $MODS_CONFIG_LOC

USER ror2
COPY --from=curl --chown=ror2 /tmp/bepinex/BepInExPack/BepInEx $INSTALL_LOC/BepInEx
COPY --from=curl --chown=ror2 /tmp/bepinex/BepInExPack/doorstop_config.ini $INSTALL_LOC
COPY --from=curl --chown=ror2 /tmp/bepinex/BepInExPack/winhttp.dll $INSTALL_LOC
RUN ln -s $MODS_LOC $INSTALL_LOC/BepInEx/plugins/rootmods
RUN ln -s $MODS_CONFIG_LOC $INSTALL_LOC/BepInEx/config

VOLUME $MODS_LOC
VOLUME $MODS_CONFIG_LOG

# R2API + BepInEx
FROM bepinex AS r2api
Expand Down
17 changes: 11 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,19 @@ If you need more fine-grained control over the server configuration, you can bin
> **Note**: you must use one of the modloader-enabled build targets for mods.
> See above.
The container comes with one volume, `/plugins`, where you should place mod files (`.dll`s) in order to load them into the game.
We suggest bind-mounting over this if you want to control your mods' directory structure yourself; it's symlinked as a subdirectory of the `BepInEx/plugins` directory in the root game folder.
The game should recursively find mods in the folder.
The container comes with two volumes for mods:

If you need even finer-grained control over your mod structure, mount over the `/ror2/BepInEx/plugins` folder inside the container
Path | Equivalent Client Path | Purpose
---|---|---
`/plugins` | `BepInEx/plugins/rootmods` | mod files, `.dll`s etc; this is a subfolder as to not override the modloader's files. The game should find files here recursively.
`/plugin_config` | `BepInEx/config` | mod config files

We suggest bind-mounting over these directories to manage your mods, but they are declared as volumes for convenience.

If you need even finer-grained control over your mod structure, you can mount over the `/ror2/BepInEx/plugins` or `/ror2/BepInEx` folders inside the container

> Note that **this will override the `enigmaticthunder` and `r2api` targets' content; it will be as if you used the `bepinex` target.**
> If you need those tools, either use those targets, or use this method and put them in the folder you've mounted in.
> Note that this may **override the content automatically installed by the image** depending which you mount over.
> If you need these tools, we suggest using the provided targets, but if you use the above method then you'll need to install the tools manually.
See the [Risk of Rain 2 Modding Wiki](https://github.com/risk-of-thunder/R2Wiki/wiki) for more information.

Expand Down

0 comments on commit 3f0dd03

Please sign in to comment.