Notice: ./docker/domserver/scripts/start.d/50-domjudge.sh:25:13: note: Possible misspelling: MYSQL_HOST may not be assigned. Did you mean MYSQL_PORT? [SC2153]
The environment variable MYSQL_HOST is in fact set in the Dockerfile, but ShellCheck doesn't know that.
Abort if the variable is unset (using the parameter expansion ${VAR:?message}), to teach ShellCheck that this variable exists and to give a clear error message if somehow the variable is unset.
Error message:
The environment variable MYSQL_HOST is in fact set in the Dockerfile, but ShellCheck doesn't know that.
Abort if the variable is unset (using the parameter expansion
${VAR:?message}
), to teach ShellCheck that this variable exists and to give a clear error message if somehow the variable is unset.Also check some other variables for consistency.