Skip to content

Commit

Permalink
fix: add checks for installed ZMQ version and DRAFT_API
Browse files Browse the repository at this point in the history
  • Loading branch information
AlvinSchiller committed Apr 17, 2024
1 parent 24f1314 commit ad774e8
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions installation/routines/setup_jukebox_core.sh
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,20 @@ _jukebox_core_check() {
local pip_modules=$(get_args_from_file "${INSTALLATION_PATH}/requirements.txt")
verify_pip_modules pyzmq $pip_modules

log " Verify ZMQ version '${JUKEBOX_ZMQ_VERSION}'"
local zmq_version=$(python -c 'import zmq; print(f"{zmq.zmq_version()}")')
if [[ "${zmq_version}" != "${JUKEBOX_ZMQ_VERSION}" ]]; then
exit_on_error "ERROR: ZMQ version '${zmq_version}' differs from expected '${JUKEBOX_ZMQ_VERSION}'!"
fi
log " CHECK"

log " Verify ZMQ has 'DRAFT-API' activated"
local zmq_hasDraftApi=$(python -c 'import zmq; print(f"{zmq.DRAFT_API}")')
if [[ "${zmq_hasDraftApi}" != "True" ]]; then
exit_on_error "ERROR: ZMQ has 'DRAFT-API' '${zmq_hasDraftApi}' differs from expected 'True'!"
fi
log " CHECK"

verify_files_chmod_chown 644 "${CURRENT_USER}" "${CURRENT_USER_GROUP}" "${JUKEBOX_PULSE_CONFIG}"

verify_files_chmod_chown 644 "${CURRENT_USER}" "${CURRENT_USER_GROUP}" "${SETTINGS_PATH}/jukebox.yaml"
Expand Down

0 comments on commit ad774e8

Please sign in to comment.