From f3dbb4dd2db13af5f6696f659f3c9c8d95927fd2 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Mon, 26 Jul 2021 19:32:26 -0500 Subject: [PATCH] Added support for Magma dev channel downloads --- README.md | 4 +++- start-deployMagma | 9 +++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index c34dda04..9d0554cc 100644 --- a/README.md +++ b/README.md @@ -470,7 +470,9 @@ A [Magma](https://magmafoundation.org/) server, which is a combination of Forge -e TYPE=MAGMA -> **NOTE** there are limited base versions supported, so you will also need to set `VERSION`, such as "1.12.2" +By default, the "stable" channel is used, but you can set `MAGMA_CHANNEL` to "dev" to access dev channel versions. + +> **NOTE** there are limited base versions supported, so you will also need to set `VERSION`, such as "1.12.2", "" ### Running a Mohist server diff --git a/start-deployMagma b/start-deployMagma index cf590ca5..d56f1fdd 100644 --- a/start-deployMagma +++ b/start-deployMagma @@ -2,12 +2,17 @@ . ${SCRIPTS:-/}start-utils +isDebugging && set -x + +# stable, dev +: ${MAGMA_CHANNEL:=stable} + export SERVER="/data/magma-server-${VANILLA_VERSION}.jar" # Always download since new updates of each base version are published frequently if ! curl -o /data/magma-server-${VANILLA_VERSION}.jar -fsSL \ - https://api.magmafoundation.org/api/resources/Magma/${VANILLA_VERSION}/stable/latest/download; then - log "ERROR unable to download version ${VANILLA_VERSION} of Magma" + https://api.magmafoundation.org/api/resources/Magma/${VANILLA_VERSION}/${MAGMA_CHANNEL}/latest/download; then + log "ERROR unable to download version ${VANILLA_VERSION} of Magma in ${MAGMA_CHANNEL} channel" log " Check https://magmafoundation.org/ for available versions" exit 1 fi