Closed omerhodzic123 closed 1 year ago
You'll need to fill in CF_API_KEY, but I also need to add better error handling for that.
You'll need to fill in CF_API_KEY, but I also need to add better error handling for that.
I actually did have it filled in, just removed it here because wasn't sure if it should be private. I did also make sure to include the extra $ before each of its occurrences
Ah ok, I'll research it some more then.
I just noticed, your image is old. Please re-pull that and try with that.
FYI, some modpacks/mods will require manual retrieval. Got this response from CurseForge/Overwolf:
I'm going to try to work on an alternate means of bootstrapping the AUTO_CURSEFORGE inputs, but might be slow going since I have personal matters this week.
FYI, some modpacks/mods will require manual retrieval. Got this response from CurseForge/Overwolf:
I'm going to try to work on an alternate means of bootstrapping the AUTO_CURSEFORGE inputs, but might be slow going since I have personal matters this week.
Could you clarify what you mean by Manual Retrieval? I tried running the pack I have been running fine (VaultHunters) via Curseforge and via Generic Packs. Curseforge failed to boot due to missing startup scripts and Generic Packs booted but had massive performance issues.
Could you clarify what you mean by Manual Retrieval? I tried running the pack I have been running fine (VaultHunters) via Curseforge and via Generic Packs
Using generic packs mechanism is what I meant.
Generic Packs booted but had massive performance issues.
Performance issues are not caused by containerization or these install mechanisms. You'll need to investigate system performance or alternate hardware.
Could you clarify what you mean by Manual Retrieval? I tried running the pack I have been running fine (VaultHunters) via Curseforge and via Generic Packs
Using generic packs mechanism is what I meant.
Generic Packs booted but had massive performance issues.
Performance issues are not caused by containerization or these install mechanisms. You'll need to investigate system performance or alternate hardware.
So there should be no difference between a Forge + generic pack vs AUTO_CURSEFORGE
? That's not what I was seeing, at least with the pack I was using. I was using Forge 1.18.2 with GENERIC_PACK
set to the server files for the pack I was wanting to run and the resulting server crashed near instantly as soon as I logged in. I may be able to grab logs if its useful.
I eventually managed to get AUTO_CURSEFORGE
working and the server is once again running fine.
I escaped everything like you in the docu and i get every time:
2023-04-03 12:27:30 [init] Running as uid=1000 gid=1000 with /data as 'drwxrwxr-x 2 1000 1000 4096 Apr 2 23:28 /data' 2023-04-03 12:27:31 [init] Resolved version given LATEST into 1.19.4 and major version 1.19 2023-04-03 12:27:31 [init] Resolving type given AUTO_CURSEFORGE 2023-04-03 12:27:35 [mc-image-helper] 10:27:35.283 ERROR : Invalid parameter provided for 'install-curseforge' command: Access to https://api.curseforge.com/v1 is forbidden. Make sure to set CF_API_KEY to a valid API key from https://console.curseforge.com/ 2023-04-03 12:27:35 [init] ERROR failed to auto-install CurseForge modpack
i try to set up a Docker container with Minecraft Sigma on Windows. (I know not the smartest way but normalay it works) can you maby help why it came Everytime?
I escaped everything like you in the docu and i get every time:
2023-04-03 12:27:30 [init] Running as uid=1000 gid=1000 with /data as 'drwxrwxr-x 2 1000 1000 4096 Apr 2 23:28 /data' 2023-04-03 12:27:31 [init] Resolved version given LATEST into 1.19.4 and major version 1.19 2023-04-03 12:27:31 [init] Resolving type given AUTO_CURSEFORGE 2023-04-03 12:27:35 [mc-image-helper] 10:27:35.283 ERROR : Invalid parameter provided for 'install-curseforge' command: Access to https://api.curseforge.com/v1 is forbidden. Make sure to set CF_API_KEY to a valid API key from https://console.curseforge.com/ 2023-04-03 12:27:35 [init] ERROR failed to auto-install CurseForge modpack
i try to set up a Docker container with Minecraft Sigma on Windows. (I know not the smartest way but normalay it works) can you maby help why it came Everytime?
I also nkwo thast is stupis what i do but this ist the comand what i copy in PowerShelel:
docker run -it -d -v Minecraft_Sigma:/data --name Sigma -p 25566:25565 -e MEMORY=8G -e EULA=TRUE -e TYPE=CURSEFORGE -e TYPE=AUTO_CURSEFORGE -e "CF_API_KEY=\$2a\$10\$..." -e CF_PAGE_URL=https://www.curseforge.com/minecraft/modpacks/sigma itzg/minecraft-server:java8-multiarch
thx for editing. Do you have a solution?
@IceDragnon2061 try using single quotes instead of double quotes. That way the shell for sure won't interpret the $
's
Still have that problem:
[mc-image-helper] 14:03:00.177 ERROR : Invalid parameter provided for 'install-curseforge' command: Access to https://api.curseforge.com/v1 is forbidden. Make sure to set CF_API_KEY to a valid API key from https://console.curseforge.com/
ok i have found out. The comand must look like this than it works:
docker run -it -d -v Minecraft_Sigma:/data --name Sigma -p 25566:25565 -e MEMORY=8G -e EULA=TRUE -e TYPE=CURSEFORGE -e TYPE=AUTO_CURSEFORGE -e CF_API_KEY='$2a$10$uOrmaL...' -e CF_PAGE_URL=https://www.curseforge.com/minecraft/modpacks/create-above-and-beyond itzg/minecraft-server:java8-multiarch
Thanks for the update @IceDragnon2061 . I need to fix the docs since I didn't notice before that the quotes were misplaced.
Please bear in mind that the double quotes are a requirement if done via a docker-compose.yml
i.e. CF_API_KEY: "" works and CF_API_KEY: '' does not
Just tested it as was having a similar issue, single quotes will not work in the via docker compose
@R15B FWIW I just now tested with
version: "3.8"
services:
mc:
image: itzg/minecraft-server
environment:
CF_API_KEY: '$$2a$$10$$R...'
and the following
docker compose run --entrypoint env mc
includes:
CF_API_KEY=$2a$10$R...
So, it appears single or double quotes make no difference either way. $
's need to be doubled up to escape them.
Back to the OP, I am not able to recreate the original problem with the latest image. @omerhodzic123 can you confirm if this issue can be closed?
Back to the OP, I am not able to recreate the original problem with the latest image. @omerhodzic123 can you confirm if this issue can be closed?
Just tested it. Working with the latest image. Apologies for not thinking to check this earlier.
@R15B FWIW I just now tested with
version: "3.8" services: mc: image: itzg/minecraft-server environment: CF_API_KEY: '$$2a$$10$$R...'
and the following
docker compose run --entrypoint env mc
includes:
CF_API_KEY=$2a$10$R...
So, it appears single or double quotes make no difference either way.
$
's need to be doubled up to escape them.
Sorry to bounce back to this, I've not had to double up the $ signs in my docker compose file. I used single quotes initially and could not get the server to start.
I have it running without issue with the compose file configuration as below.
CF_PAGE_URL: "https://www.curseforge.com/minecraft/modpacks/all-the-mods-8"
CF_SLUG: "all-the-mods-8"
CF_FILE_ID: "4461163"
CF_API_KEY: "$2a$10$8KtpCVtni5dsxzuJEgXgi.."
When I attempted this with single quotes it continued to fail with similar errors as to described in this thread.
I'll do some further testing later today and see what I find.
That's strange then since interpolation occurs either way
https://docs.docker.com/compose/compose-file/12-interpolation/
...but go with whatever works.
Edit: the $ parts of your key start with a number so it's not getting interpreted as variables. The single quote behavior is odd still. 🤷♂️
for information the CF_API_KEY not detect the third char "$" in the key to avoid that i just add an other "$" at this position and it's work
In my CF_API_KEY, I replaced all "$" with "$$", and all works now.
docker-compose.yml
services:
mc:
image: itzg/minecraft-server
tty: true
stdin_open: true
ports:
- "25565:25565"
environment:
TYPE: "AUTO_CURSEFORGE"
# CF_SLUG: "all-the-mods-8"
CF_PAGE_URL: "https://www.curseforge.com/minecraft/modpacks/all-the-mods-8"
VERSION: "1.20.1"
# https://console.curseforge.com/#/api-keys
# CF_API_KEY: "$abcdefg$123.456"
CF_API_KEY: "$$abcdefg$$123.456"
EULA: "TRUE"
volumes:
- ./data:/data
docker compose up
Describe the problem
When trying to set up a Mechanical Mastery server I get a 'install-curseforge' command failed error. Logs below.
Container definition
Empty fields redacted.
Container logs