mirror of
https://github.com/itzg/docker-minecraft-server.git
synced 2026-02-18 07:26:24 +00:00
Compare commits
28 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8987d2cc81 | ||
|
|
45d5fd1a97 | ||
|
|
93c0cead40 | ||
|
|
195d35214b | ||
|
|
2de3efea15 | ||
|
|
0599fa64c2 | ||
|
|
94df6cca20 | ||
|
|
6fb34cd256 | ||
|
|
0d5e44a338 | ||
|
|
cffe4012aa | ||
|
|
909ea4e214 | ||
|
|
106996f06f | ||
|
|
d672b3878f | ||
|
|
0d71ace7df | ||
|
|
bee51671bf | ||
|
|
ab2f77d8ba | ||
|
|
f1aad07804 | ||
|
|
e7084c233e | ||
|
|
7f3c3b2d64 | ||
|
|
f6493892e5 | ||
|
|
0dd3e9e9b7 | ||
|
|
db3fbd8cd1 | ||
|
|
e01fe46645 | ||
|
|
f2b3f6ea48 | ||
|
|
8ae707954b | ||
|
|
08d8472579 | ||
|
|
0f359dbf82 | ||
|
|
e217ac503e |
2
.github/workflows/stale-check.yml
vendored
2
.github/workflows/stale-check.yml
vendored
@@ -12,7 +12,7 @@ jobs:
|
||||
pull-requests: write
|
||||
steps:
|
||||
- name: Process Stale Issues
|
||||
uses: actions/stale@v7
|
||||
uses: actions/stale@v8
|
||||
with:
|
||||
stale-issue-label: status/stale
|
||||
stale-pr-label: status/stale
|
||||
|
||||
16
Dockerfile
16
Dockerfile
@@ -3,11 +3,17 @@
|
||||
ARG BASE_IMAGE=eclipse-temurin:17-jre-focal
|
||||
FROM ${BASE_IMAGE}
|
||||
|
||||
# hook into docker BuildKit --platform support
|
||||
# see https://docs.docker.com/engine/reference/builder/#automatic-platform-args-in-the-global-scope
|
||||
ARG TARGETOS
|
||||
ARG TARGETARCH
|
||||
ARG TARGETVARIANT
|
||||
|
||||
# CI system should set this to a hash or git revision of the build directory and it's contents to
|
||||
# ensure consistent cache updates.
|
||||
ARG BUILD_FILES_REV=1
|
||||
RUN --mount=target=/build,source=build \
|
||||
REV=${BUILD_FILES_REV} /build/run.sh install-packages
|
||||
REV=${BUILD_FILES_REV} TARGET=${TARGETARCH}${TARGETVARIANT} /build/run.sh install-packages
|
||||
|
||||
RUN --mount=target=/build,source=build \
|
||||
REV=${BUILD_FILES_REV} /build/run.sh setup-user
|
||||
@@ -16,12 +22,6 @@ COPY --chmod=644 files/sudoers* /etc/sudoers.d
|
||||
|
||||
EXPOSE 25565
|
||||
|
||||
# hook into docker BuildKit --platform support
|
||||
# see https://docs.docker.com/engine/reference/builder/#automatic-platform-args-in-the-global-scope
|
||||
ARG TARGETOS
|
||||
ARG TARGETARCH
|
||||
ARG TARGETVARIANT
|
||||
|
||||
ARG EASY_ADD_VER=0.7.1
|
||||
ADD https://github.com/itzg/easy-add/releases/download/${EASY_ADD_VER}/easy-add_${TARGETOS}_${TARGETARCH}${TARGETVARIANT} /usr/bin/easy-add
|
||||
RUN chmod +x /usr/bin/easy-add
|
||||
@@ -46,7 +46,7 @@ RUN easy-add --var os=${TARGETOS} --var arch=${TARGETARCH}${TARGETVARIANT} \
|
||||
--var version=0.1.1 --var app=maven-metadata-release --file {{.app}} \
|
||||
--from https://github.com/itzg/{{.app}}/releases/download/{{.version}}/{{.app}}_{{.version}}_{{.os}}_{{.arch}}.tar.gz
|
||||
|
||||
ARG MC_HELPER_VERSION=1.25.11
|
||||
ARG MC_HELPER_VERSION=1.26.2
|
||||
ARG MC_HELPER_BASE_URL=https://github.com/itzg/mc-image-helper/releases/download/${MC_HELPER_VERSION}
|
||||
RUN curl -fsSL ${MC_HELPER_BASE_URL}/mc-image-helper-${MC_HELPER_VERSION}.tgz \
|
||||
| tar -C /usr/share -zxf - \
|
||||
|
||||
54
README.md
54
README.md
@@ -5,6 +5,12 @@
|
||||
[](https://github.com/itzg/docker-minecraft-server/actions)
|
||||
[](https://www.buymeacoffee.com/itzg)
|
||||
|
||||
---
|
||||
|
||||
## [View the documentation](https://itzg.github.io/docker-minecraft-docs/)
|
||||
|
||||
---
|
||||
|
||||
## Intro
|
||||
|
||||
This docker image provides a Minecraft Server that will automatically download the latest stable
|
||||
@@ -616,6 +622,33 @@ docker run -d --name mc-ftb -e EULA=TRUE \
|
||||
To manage a CurseForge modpack automatically with upgrade support, pinned or latest version tracking, set `TYPE` to "AUTO_CURSEFORGE". The appropriate mod loader (Forge / Fabric) version will be automatically installed as declared by the modpack. This mode will also take care of cleaning up unused files installed by previous versions of the modpack, but world data is never auto-removed.
|
||||
|
||||
> **NOTES:**
|
||||
>
|
||||
> A CurseForge API key is **required** to use this feature. Go to their [developer console](https://console.curseforge.com/), generate an API key, and set the environment variable `CF_API_KEY`.
|
||||
>
|
||||
> When entering your API Key in a docker compose file you will need to escape any `$` character with a second `$`.
|
||||
>
|
||||
> Example if your key is `$11$22$33aaaaaaaaaaaaaaaaaaaaaaaaaa`:
|
||||
> ```yaml
|
||||
> environment:
|
||||
> CF_API_KEY: '$$11$$22$$33aaaaaaaaaaaaaaaaaaaaaaaaaa'
|
||||
> ```
|
||||
> If you use `docker run` you will need to make sure to use single quotes:
|
||||
>
|
||||
> ```shell
|
||||
> docker run ... -e CF_API_KEY='$11$22$33aaaaaaaaaaaaaaaaaaaaaaaaaa'
|
||||
> ```
|
||||
>
|
||||
> To avoid exposing the API key, it is highly recommended to use a `.env` file, which is [loaded automatically by docker compose](https://docs.docker.com/compose/environment-variables/set-environment-variables/#substitute-with-an-env-file). `$`'s in the value still need to escaped with a second `$` and the variable needs to be referenced from the compose file, such as:
|
||||
> ```yaml
|
||||
> environment:
|
||||
> CF_API_KEY: ${CF_API_KEY}
|
||||
> ```
|
||||
>
|
||||
> To use the equivalent with `docker run` you need to specify the `.env` file explicitly:
|
||||
> ```
|
||||
> docker run --env-file=.env itzg/minecraft-server
|
||||
> ```
|
||||
>
|
||||
> Be sure to use the appropriate [image tag for the Java version compatible with the modpack](#running-minecraft-server-on-different-java-version).
|
||||
>
|
||||
> Most modpacks require a good amount of memory, so it best to set `MEMORY` to at least "4G" since the default is only 1 GB.
|
||||
@@ -637,6 +670,8 @@ For example:
|
||||
-e TYPE=AUTO_CURSEFORGE -e CF_SLUG=all-the-mods-8
|
||||
```
|
||||
|
||||
If the authors of the modpack have disallowed project distribution, then the desired **client** modpack zip will need to be manually downloaded and made available to the container. The path to that file must be passed to `CF_MODPACK_ZIP`.
|
||||
|
||||
The latest file will be located and used by default, but if a specific version is desired you can use one of the following options. With any of these options **do not select a server file** -- they lack the required manifest and defeat the ability to consistently automate startup.
|
||||
|
||||
- Use `CF_PAGE_URL`, but include the full URL to a specific file
|
||||
@@ -663,9 +698,9 @@ The following examples all refer to version 1.0.7 of ATM8:
|
||||
|
||||
Quite often there are mods that need to be excluded, such as ones that did not properly declare as a client mod via the file's game versions. Similarly, there are some mods that are incorrectly tagged as client only. The following describes two options to exclude/include mods:
|
||||
|
||||
Global and per modpack exclusions can be declared in a JSON file and referenced with `CF_EXCLUDE_INCLUDE_FILE`. By default, [the file bundled with the image](files/cf-exclude-include.json) will be used. The schema of this file [is documented here](https://github.com/itzg/mc-image-helper#excludeinclude-file-schema).
|
||||
Global and per modpack exclusions can be declared in a JSON file and referenced with `CF_EXCLUDE_INCLUDE_FILE`. By default, [the file bundled with the image](files/cf-exclude-include.json) will be used, but can be disabled by setting this to an empty string. The schema of this file [is documented here](https://github.com/itzg/mc-image-helper#excludeinclude-file-schema).
|
||||
|
||||
Alternatively, they can be excluded by passing a comma or space delimited list of **project** slugs or IDs via `CF_EXCLUDE_MODS`. Similarly, there are some mods that are incorrectly tagged as client only. For those, pass the **project** slugs or IDs via `CF_FORCE_INCLUDE_MODS`. If either of these are set, then `CF_EXCLUDE_INCLUDE_FILE` will be **disabled**.
|
||||
Alternatively, they can be excluded by passing a comma or space delimited list of **project** slugs or IDs via `CF_EXCLUDE_MODS`. Similarly, there are some mods that are incorrectly tagged as client only. For those, pass the **project** slugs or IDs via `CF_FORCE_INCLUDE_MODS`. These lists will be combined with the content of the exclude/include file, if given.
|
||||
|
||||
A mod's project ID can be obtained from the right hand side of the project page:
|
||||

|
||||
@@ -1870,6 +1905,21 @@ The following environment variables define the behaviour of auto-pausing:
|
||||
|
||||
> To troubleshoot, add `DEBUG_AUTOPAUSE=true` to see additional output
|
||||
|
||||
### Rootless Autopause
|
||||
|
||||
If you're running the container as rootless, you might need to set change the default port forwarder from RootlessKit to slirp4netns.
|
||||
|
||||
For Docker, see the following for setup:
|
||||
* https://docs.docker.com/engine/security/rootless/#networking-errors
|
||||
* https://rootlesscontaine.rs/getting-started/docker/#changing-the-port-forwarder
|
||||
|
||||
For Podman, see the following for setup:
|
||||
* https://rootlesscontaine.rs/getting-started/podman/#changing-the-port-forwarder
|
||||
* Run with
|
||||
```
|
||||
-e AUTOPAUSE_KNOCK_INTERFACE=tap0 --cap-add=CAP_NET_RAW --network slirp4netns:port_handler=slirp4netns
|
||||
```
|
||||
|
||||
## Autostop
|
||||
|
||||
An option to stop the server after a specified time has been added for niche applications (e.g. billing saving on AWS Fargate). The function is incompatible with the Autopause functionality, as they basically cancel out each other.
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
set -o pipefail
|
||||
|
||||
apk add --no-cache -U \
|
||||
openssl \
|
||||
@@ -21,7 +22,12 @@ apk add --no-cache -U \
|
||||
rsync \
|
||||
nano \
|
||||
sudo \
|
||||
knock \
|
||||
tar \
|
||||
zstd \
|
||||
nfs-utils
|
||||
nfs-utils \
|
||||
libpcap
|
||||
|
||||
# Patched knockd
|
||||
curl -fsSL -o /tmp/knock.tar.gz https://github.com/Metalcape/knock/releases/download/0.8.1/knock-0.8.1-alpine-amd64.tar.gz
|
||||
tar -xf /tmp/knock.tar.gz -C /usr/local/ && rm /tmp/knock.tar.gz
|
||||
ln -s /usr/local/sbin/knockd /usr/sbin/knockd
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
export TARGET
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
microdnf install dnf -y
|
||||
|
||||
@@ -33,6 +35,11 @@ dnf install -y ImageMagick \
|
||||
unzip \
|
||||
zstd \
|
||||
lbzip2 \
|
||||
knock
|
||||
libpcap
|
||||
|
||||
bash /build/ol/install-gosu.sh
|
||||
|
||||
# Patched knockd
|
||||
curl -fsSL -o /tmp/knock.tar.gz https://github.com/Metalcape/knock/releases/download/0.8.1/knock-0.8.1-$TARGET.tar.gz
|
||||
tar -xf /tmp/knock.tar.gz -C /usr/local/ && rm /tmp/knock.tar.gz
|
||||
ln -s /usr/local/sbin/knockd /usr/sbin/knockd
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
export TARGET
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
apt-get update
|
||||
|
||||
@@ -23,7 +25,13 @@ apt-get install -y \
|
||||
unzip \
|
||||
zstd \
|
||||
lbzip2 \
|
||||
knockd \
|
||||
nfs-common
|
||||
nfs-common \
|
||||
libpcap0.8
|
||||
|
||||
apt-get clean
|
||||
apt-get clean
|
||||
|
||||
# Patched knockd
|
||||
curl -fsSL -o /tmp/knock.tar.gz https://github.com/Metalcape/knock/releases/download/0.8.1/knock-0.8.1-$TARGET.tar.gz
|
||||
tar -xf /tmp/knock.tar.gz -C /usr/local/ && rm /tmp/knock.tar.gz
|
||||
ln -s /usr/local/sbin/knockd /usr/sbin/knockd
|
||||
find /usr/lib -name 'libpcap.so.0.8' -execdir cp '{}' libpcap.so.1 \;
|
||||
|
||||
@@ -8,6 +8,7 @@ services:
|
||||
environment:
|
||||
EULA: "true"
|
||||
TYPE: AUTO_CURSEFORGE
|
||||
CF_API_KEY: # allocate from https://console.curseforge.com/
|
||||
CF_PAGE_URL: https://www.curseforge.com/minecraft/modpacks/all-the-mods-8
|
||||
CF_FILENAME_MATCHER: "1.0.6"
|
||||
MEMORY: 4G
|
||||
|
||||
1
examples/one-block-modded/.gitignore
vendored
Normal file
1
examples/one-block-modded/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
/.env
|
||||
@@ -8,12 +8,19 @@ services:
|
||||
environment:
|
||||
EULA: "true"
|
||||
TYPE: AUTO_CURSEFORGE
|
||||
CF_PAGE_URL: "https://www.curseforge.com/minecraft/modpacks/one-block-modded/files/4136487"
|
||||
# CF_API_KEY=... must be set in .env file or as environment variable
|
||||
CF_API_KEY: ${CF_API_KEY}
|
||||
CF_SLUG: one-block-modded
|
||||
# Modpack client zip must be manually downloaded from
|
||||
# https://www.curseforge.com/minecraft/modpacks/one-block-modded
|
||||
# due to authors disallowing project distribution
|
||||
CF_MODPACK_ZIP: /modpacks/Modded+OneBock.zip
|
||||
CF_SET_LEVEL_FROM: OVERRIDES
|
||||
DEBUG: "false"
|
||||
MEMORY: 4G
|
||||
volumes:
|
||||
- mc-data:/data
|
||||
- ./modpacks:/modpacks:ro
|
||||
|
||||
volumes:
|
||||
mc-data: {}
|
||||
@@ -8,6 +8,7 @@ services:
|
||||
environment:
|
||||
EULA: "true"
|
||||
TYPE: AUTO_CURSEFORGE
|
||||
CF_API_KEY: # allocate from https://console.curseforge.com/
|
||||
CF_SLUG: the-pixelmon-modpack
|
||||
CF_FILENAME_MATCHER: "9.1.2"
|
||||
MEMORY: 4G
|
||||
|
||||
19
examples/valhesia5/docker-compose.yml
Normal file
19
examples/valhesia5/docker-compose.yml
Normal file
@@ -0,0 +1,19 @@
|
||||
version: "3.8"
|
||||
|
||||
services:
|
||||
mc:
|
||||
image: itzg/minecraft-server
|
||||
ports:
|
||||
- "25565:25565"
|
||||
environment:
|
||||
EULA: "true"
|
||||
TYPE: AUTO_CURSEFORGE
|
||||
CF_API_KEY: # allocate from https://console.curseforge.com/
|
||||
CF_FORCE_SYNCHRONIZE: "true"
|
||||
CF_PAGE_URL: https://www.curseforge.com/minecraft/modpacks/valhelsia-5/files/4429560
|
||||
MEMORY: 4G
|
||||
volumes:
|
||||
- data:/data
|
||||
|
||||
volumes:
|
||||
data: {}
|
||||
@@ -25,3 +25,19 @@ services:
|
||||
VERSION: ${MINECRAFT_VERSION:-LATEST}
|
||||
VANILLATWEAKS_SHARECODE: MGr52E
|
||||
REMOVE_OLD_VANILLATWEAKS: "TRUE"
|
||||
vanillatweaks_file_datapacks_and_resourcepacks_and_craftingtweaks:
|
||||
# port is set to 25567 to not conflict with vanillatweaks_file example
|
||||
restart: "no"
|
||||
image: itzg/minecraft-server
|
||||
ports:
|
||||
- "25567:25565/tcp"
|
||||
environment:
|
||||
EULA: "TRUE"
|
||||
VERSION: ${MINECRAFT_VERSION:-LATEST}
|
||||
VANILLATWEAKS_FILE: /config/vanillatweaks-datapacks.json,/config/vanillatweaks-resourcepacks.json,/config/vanillatweaks-craftingtweaks.json
|
||||
REMOVE_OLD_VANILLATWEAKS: "TRUE"
|
||||
volumes:
|
||||
- data:/data
|
||||
- ./vanillatweaks-datapacks.json:/config/vanillatweaks-datapacks.json:ro
|
||||
- ./vanillatweaks-resourcepacks.json:/config/vanillatweaks-resourcepacks.json:ro
|
||||
- ./vanillatweaks-craftingtweaks.json:/config/vanillatweaks-craftingtweaks.json:ro
|
||||
|
||||
12
examples/vanilla-tweaks/vanillatweaks-craftingtweaks.json
Normal file
12
examples/vanilla-tweaks/vanillatweaks-craftingtweaks.json
Normal file
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"type": "craftingtweaks",
|
||||
"version": "1.18",
|
||||
"packs": {
|
||||
"quality of life": [
|
||||
"dropper to dispenser",
|
||||
"double slabs",
|
||||
"back to blocks"
|
||||
]
|
||||
},
|
||||
"result": "ok"
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
{
|
||||
"type": "datapacks",
|
||||
"version": "1.18",
|
||||
"packs": {
|
||||
"survival": [
|
||||
@@ -11,5 +12,6 @@
|
||||
"coordinates hud"
|
||||
],
|
||||
"items": ["armored elytra"]
|
||||
}
|
||||
},
|
||||
"result": "ok"
|
||||
}
|
||||
|
||||
8
examples/vanilla-tweaks/vanillatweaks-resourcepacks.json
Normal file
8
examples/vanilla-tweaks/vanillatweaks-resourcepacks.json
Normal file
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"type": "resourcepacks",
|
||||
"version": "1.18",
|
||||
"packs": {
|
||||
"aesthetic": ["CherryPicking", "BlackNetherBricks", "AlternateBlockDestruction"]
|
||||
},
|
||||
"result": "ok"
|
||||
}
|
||||
@@ -8,6 +8,7 @@ services:
|
||||
environment:
|
||||
EULA: "true"
|
||||
TYPE: AUTO_CURSEFORGE
|
||||
CF_API_KEY: # allocate from https://console.curseforge.com/
|
||||
CF_SLUG: vault-hunters-1-18-2
|
||||
CF_FILENAME_MATCHER: "Update-6H"
|
||||
MEMORY: 4G
|
||||
|
||||
@@ -45,7 +45,7 @@ if isTrue "${DEBUG_AUTOPAUSE}"; then
|
||||
knockdArgs+=(-D)
|
||||
fi
|
||||
|
||||
sudo /usr/sbin/knockd "${knockdArgs[@]}"
|
||||
sudo /usr/local/sbin/knockd "${knockdArgs[@]}"
|
||||
if [ $? -ne 0 ] ; then
|
||||
logAutopause "Failed to start knockd daemon."
|
||||
logAutopause "Probable cause: Unable to attach to interface \"$AUTOPAUSE_KNOCK_INTERFACE\"."
|
||||
|
||||
@@ -13,3 +13,4 @@
|
||||
[unpauseMCServer-bedrock]
|
||||
sequence = 19132:udp
|
||||
command = /auto/resume.sh %IP%
|
||||
seq_cooldown = 60
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
"extreme-sound-muffler",
|
||||
"ignitioncoil",
|
||||
"legendary-tooltips",
|
||||
"neat",
|
||||
"nekos-enchanted-books",
|
||||
"not-enough-animations",
|
||||
"oculus",
|
||||
@@ -23,6 +24,11 @@
|
||||
"forceIncludes": [
|
||||
"revelationary"
|
||||
]
|
||||
},
|
||||
"valhelsia-5": {
|
||||
"excludes": [
|
||||
"modernfix"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
minecraft ALL=(ALL) NOPASSWD:/usr/bin/pkill
|
||||
minecraft ALL=(ALL) NOPASSWD:/usr/sbin/knockd
|
||||
minecraft ALL=(ALL) NOPASSWD:/usr/local/sbin/knockd
|
||||
|
||||
@@ -84,4 +84,9 @@ elif [[ -z "$MAX_TICK_TIME" ]] ; then
|
||||
export MAX_TICK_TIME
|
||||
fi
|
||||
|
||||
# seq_cooldown cannot be larger than AUTOPAUSE_TIMEOUT_KN, otherwise the server may
|
||||
# become paused while knockd is still ignoring packets, preventing players from joining.
|
||||
let COOLDOWN=$AUTOPAUSE_TIMEOUT_KN/2
|
||||
sed -i "s/\(seq_cooldown *= *\).*/\1$COOLDOWN/" /tmp/knockd-config.cfg
|
||||
|
||||
/auto/autopause-daemon.sh &
|
||||
|
||||
@@ -197,6 +197,7 @@ case "${TYPE^^}" in
|
||||
;;
|
||||
|
||||
AUTO_CURSEFORGE)
|
||||
evaluateJavaCompatibilityForForge
|
||||
exec "${SCRIPTS:-/}start-deployAutoCF" "$@"
|
||||
;;
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ set -eu
|
||||
: "${CF_FILENAME_MATCHER:=}"
|
||||
: "${CF_PARALLEL_DOWNLOADS:=4}"
|
||||
: "${CF_FORCE_SYNCHRONIZE:=false}"
|
||||
: "${CF_EXCLUDE_INCLUDE_FILE:=https://raw.githubusercontent.com/itzg/docker-minecraft-server/master/files/cf-exclude-include.json}"
|
||||
: "${CF_EXCLUDE_INCLUDE_FILE=https://raw.githubusercontent.com/itzg/docker-minecraft-server/master/files/cf-exclude-include.json}"
|
||||
: "${CF_EXCLUDE_MODS:=}"
|
||||
: "${CF_FORCE_INCLUDE_MODS:=}"
|
||||
: "${CF_SET_LEVEL_FROM:=}" # --set-level-from
|
||||
@@ -45,17 +45,14 @@ args+=(
|
||||
--overrides-skip-existing="$CF_OVERRIDES_SKIP_EXISTING"
|
||||
)
|
||||
|
||||
if [[ $CF_EXCLUDE_MODS || $CF_FORCE_INCLUDE_MODS ]]; then
|
||||
if [[ $CF_EXCLUDE_MODS ]]; then
|
||||
args+=( --exclude-mods="$CF_EXCLUDE_MODS" )
|
||||
fi
|
||||
if [[ $CF_FORCE_INCLUDE_MODS ]]; then
|
||||
args+=( --force-include-mods="$CF_FORCE_INCLUDE_MODS" )
|
||||
fi
|
||||
else
|
||||
if [[ $CF_EXCLUDE_INCLUDE_FILE ]]; then
|
||||
args+=( --exclude-include-file="$CF_EXCLUDE_INCLUDE_FILE" )
|
||||
fi
|
||||
if [[ $CF_EXCLUDE_MODS ]]; then
|
||||
args+=( --exclude-mods="$CF_EXCLUDE_MODS" )
|
||||
fi
|
||||
if [[ $CF_FORCE_INCLUDE_MODS ]]; then
|
||||
args+=( --force-include-mods="$CF_FORCE_INCLUDE_MODS" )
|
||||
fi
|
||||
if [[ $CF_EXCLUDE_INCLUDE_FILE ]]; then
|
||||
args+=( --exclude-include-file="$CF_EXCLUDE_INCLUDE_FILE" )
|
||||
fi
|
||||
|
||||
if ! mc-image-helper install-curseforge "${args[@]}"; then
|
||||
|
||||
@@ -7,11 +7,13 @@
|
||||
. "${SCRIPTS:-$(dirname "$0")}/start-utils"
|
||||
isDebugging && set -x
|
||||
|
||||
# NOTE: VERSION rather than VANILLA_VERSION is specified to allow for latest supported
|
||||
# Forge version to be selected.
|
||||
if [[ ${FORGE_INSTALLER} ]]; then
|
||||
if ! mc-image-helper install-forge \
|
||||
--output-directory=/data \
|
||||
--results-file=/data/.run-forge.env \
|
||||
--minecraft-version="${VANILLA_VERSION}" \
|
||||
--minecraft-version="${VERSION}" \
|
||||
--forge-installer="${FORGE_INSTALLER}" \
|
||||
--force-reinstall="${FORGE_FORCE_REINSTALL}"; then
|
||||
log "ERROR failed to install Forge given installer ${FORGE_INSTALLER}"
|
||||
@@ -22,7 +24,7 @@ else
|
||||
if ! mc-image-helper install-forge \
|
||||
--output-directory=/data \
|
||||
--results-file=/data/.run-forge.env \
|
||||
--minecraft-version="${VANILLA_VERSION}" \
|
||||
--minecraft-version="${VERSION}" \
|
||||
--forge-version="${FORGE_VERSION}" \
|
||||
--force-reinstall="${FORGE_FORCE_REINSTALL}"; then
|
||||
log "ERROR failed to install Forge"
|
||||
|
||||
@@ -275,7 +275,7 @@ function handleModrinthProjects() {
|
||||
if [[ $MODRINTH_PROJECTS ]] && isFamily HYBRID FORGE FABRIC SPIGOT; then
|
||||
if isFamily HYBRID FORGE; then
|
||||
loader=forge
|
||||
elif isFaily FABRIC; then
|
||||
elif isFamily FABRIC; then
|
||||
loader=fabric
|
||||
else
|
||||
# we're left with Bukkit/Spigot down-lines where plugins seem to be
|
||||
|
||||
@@ -7,6 +7,7 @@ services:
|
||||
EULA: "true"
|
||||
SETUP_ONLY: "TRUE"
|
||||
TYPE: AUTO_CURSEFORGE
|
||||
CF_API_KEY: ${CF_API_KEY}
|
||||
CF_SLUG: the-pixelmon-modpack
|
||||
CF_FILENAME_MATCHER: "9.1.2"
|
||||
# Use the image bundled one to ensure latest is being tested
|
||||
|
||||
1
tests/setuponlytests/auto_curseforge/require.sh
Executable file
1
tests/setuponlytests/auto_curseforge/require.sh
Executable file
@@ -0,0 +1 @@
|
||||
[[ $CF_API_KEY ]] || exit 1
|
||||
2
tests/setuponlytests/packwiz/require.sh
Executable file
2
tests/setuponlytests/packwiz/require.sh
Executable file
@@ -0,0 +1,2 @@
|
||||
# maven.packwiz.infra.link is not resolvable
|
||||
exit 1
|
||||
Reference in New Issue
Block a user