diff --git a/docker-compose.yml b/docker-compose.yml index 7a91dc2..0b59c63 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -8,6 +8,7 @@ services: STEAM_USER: testo STEAM_PASSWORD: testo WORKSHOP_COLLECTION: 1400118996 + MOD_EXCLUDE: 667953829,1210050323,925018569,837729515,2041057379 volumes: - arma3_dev_game:/home/steam/server - arma3_dev_mods:/home/steam/volumes/mods diff --git a/entrypoint.sh b/entrypoint.sh index 71b0106..ca8411f 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -51,18 +51,23 @@ mkdir -p "$MOD_LINK_DIR" rm -f "$MOD_LINK_DIR"/* MODS_TO_LOAD="" +MOD_EXCLUDE=${MOD_EXCLUDE:=""} for mod_id in $(curl -s "https://steamcommunity.com/sharedfiles/filedetails/?id=$WORKSHOP_COLLECTION" | grep -E 'id="sharedfile_[0-9]+"' | sed 's/.*id="sharedfile_\([0-9]\+\)".*/\1/') do - # Check if directory exists - if [ ! -d "$VOLUME_HOME/mods/$mod_id" ]; then - echo "Could not find mod directory for $mod_id" - echo "Try to download it first" - exit 1 - fi - ln -s "$VOLUME_HOME/mods/$mod_id" "$MOD_LINK_DIR/$mod_id" - MODS_TO_LOAD="${MODS_TO_LOAD}mods/${mod_id};" + # Check if mod is excluded + if [[ "$MOD_EXCLUDE" == *"$mod_id"* ]]; then + # Check if directory exists + if [ ! -d "$VOLUME_HOME/mods/$mod_id" ]; then + echo "Could not find mod directory for $mod_id" + echo "Try to download it first" + exit 1 + fi + + ln -s "$VOLUME_HOME/mods/$mod_id" "$MOD_LINK_DIR/$mod_id" + MODS_TO_LOAD="${MODS_TO_LOAD}mods/${mod_id};" + fi done if [ -n "$MODS_TO_LOAD" ]; then