Corrupt jar File with mscs update
HappyWarbird opened this issue · comments
mscs force-update downloads corrupt jar files since end of April, looks like amazonaws changed something. Here's the list of /server folder
-rw-r--r-- 1 minecraft minecraft 31534189 Apr 5 16:56 minecraft_server.18w14b.jar
-rw-r--r-- 1 minecraft minecraft 31583033 Apr 12 11:00 minecraft_server.18w15a.jar
-rw-r--r-- 1 minecraft minecraft 31620910 Apr 20 15:59 minecraft_server.18w16a.jar
-rw-r--r-- 1 minecraft minecraft 0 May 15 06:00 minecraft_server.18w19b.jar
-rw-r--r-- 1 minecraft minecraft 0 May 16 06:00 minecraft_server.18w20a.jar
-rw-r--r-- 1 minecraft minecraft 0 May 17 06:00 minecraft_server.18w20b.jar
Manual DL from minecraft.net is working normal.
Entry in mscs.defaults
https://s3.amazonaws.com/Minecraft.Download/versions/$SERVER_VERSION/minecraft_server.$SERVER_VERSION.jar
Replaced $SERVER_VERSION with the Snapshot 18w20c occurs in AccessDenied on amazonaws.
Replaced $SERVER_VERSION with Release 1.12.2 works.
I think i found the issue:
http://s3.amazonaws.com/Minecraft.Download/versions/versions.json
says
__comment": "This URL is being phased out! Please update your scripts to check https://launchermeta.mojang.com/mc/game/version_manifest.json instead. Thanks <3 --Dinnerbone"
The download links in https://launchermeta.mojang.com/mc/game/version_manifest.json
work.
So mscs may need an update to continue supporting the latest minecraft versions.
I would help here, but i'm not that familiar with bash scripting.
I think the code was switched to use https://launchermeta.mojang.com/mc/game/version_manifest.json
a long time ago.
Although the client download URL (mscs-default-client-url
) still points to:
https://s3.amazonaws.com/Minecraft.Download/versions/\$CLIENT_VERSION/\$CLIENT_VERSION.jar
And the server download URL (mscs-default-server-url
) points to:
https://s3.amazonaws.com/Minecraft.Download/versions/\$SERVER_VERSION/minecraft_server.\$SERVER_VERSION.jar
The script may need to be updated to use the client URL from version_manifest.json
but I'm not sure how the server URL was changed.
The script does use the updated version_manifest.json
, but it does not parse the url field. We should probably do so. This url points to another json file that actually contains the url for the client and server downloads. This would require changes to the getClientURL()
and getServerURL()
subroutines in the script, and would probably require dropping the mscs-default-client-url
and mscs-default-server-url
variables. I don't know how dropping these two variables would affect server software provided by other entities (e.g. BungeeCord, SpigotMC, etc).
I would use those settings as an override, if they are blank then parse the URL from version_manifest.json
Please take a look at PR #189. I think this should do the trick.
Ok, PR #191 should do the trick.
I accepted PR #191, so closing this issue.