Forráskód Böngészése

[Config] CIDR API_ALLOW_FROM only allowed via API

andryyy 5 éve
szülő
commit
066b23bb02
2 módosított fájl, 2 hozzáadás és 0 törlés
  1. 1 0
      generate_config.sh
  2. 1 0
      update.sh

+ 1 - 0
generate_config.sh

@@ -285,6 +285,7 @@ IPV6_NETWORK=fd4d:6169:6c63:6f77::/64
 # An API key defined as API_KEY_READ_ONLY has read-only access
 # An API key defined as API_KEY_READ_ONLY has read-only access
 # Allowed chars for API_KEY and API_KEY_READ_ONLY: a-z, A-Z, 0-9, -
 # Allowed chars for API_KEY and API_KEY_READ_ONLY: a-z, A-Z, 0-9, -
 # You can define API_KEY and/or API_KEY_READ_ONLY
 # You can define API_KEY and/or API_KEY_READ_ONLY
+# Using CIDR is not yet implemented within mailcow.conf, use the UI to allow networks.
 
 
 #API_KEY=
 #API_KEY=
 #API_KEY_READ_ONLY=
 #API_KEY_READ_ONLY=

+ 1 - 0
update.sh

@@ -262,6 +262,7 @@ for option in ${CONFIG_ARRAY[@]}; do
     if ! grep -q ${option} mailcow.conf; then
     if ! grep -q ${option} mailcow.conf; then
       echo "Adding new option \"${option}\" to mailcow.conf"
       echo "Adding new option \"${option}\" to mailcow.conf"
       echo '# Must be set for API_KEY to be active' >> mailcow.conf
       echo '# Must be set for API_KEY to be active' >> mailcow.conf
+      echo '# IPs only, no networks (networks can be set via UI)' >> mailcow.conf
       echo "#API_ALLOW_FROM=" >> mailcow.conf
       echo "#API_ALLOW_FROM=" >> mailcow.conf
     fi
     fi
   elif [[ ${option} == "SNAT_TO_SOURCE" ]]; then
   elif [[ ${option} == "SNAT_TO_SOURCE" ]]; then