mirror of
https://github.com/itzg/docker-minecraft-server.git
synced 2026-02-17 07:03:57 +00:00
Use HTTP accept when downloading CF modpack (#1837)
This commit is contained in:
@@ -42,7 +42,7 @@ downloadModpack() {
|
||||
srv_modpack=${FTB_SERVER_MOD}
|
||||
if isURL "${srv_modpack}"; then
|
||||
log "Downloading modpack from ${srv_modpack}..."
|
||||
if ! srv_modpack=$(get -o /data --output-filename --skip-existing "${srv_modpack}"); then
|
||||
if ! srv_modpack=$(get -o /data --output-filename --skip-existing --accept=application/zip "${srv_modpack}"); then
|
||||
log "ERROR: failed to download modpack"
|
||||
exit 1
|
||||
fi
|
||||
@@ -59,11 +59,6 @@ downloadModpack() {
|
||||
log "FTB server modpack ${srv_modpack} not found."
|
||||
exit 2
|
||||
fi
|
||||
if [[ ! "${srv_modpack: -4}" == ".zip" ]]; then
|
||||
log "FTB server modpack ${srv_modpack} is not a zip archive."
|
||||
log "Please set FTB_SERVER_MOD to a file with a .zip extension."
|
||||
exit 2
|
||||
fi
|
||||
FTB_SERVER_MOD=${srv_modpack}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user