From 3aff0d9d7e23a16664781650e6519b64f146aed0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Slavi=C5=A1a=20Are=C5=BEina?= <58952836+tremor021@users.noreply.github.com> Date: Wed, 17 Sep 2025 16:42:37 +0200 Subject: [PATCH] RabbitMQ: Update repositories (#7689) * Update repos * Update * Update * Update --- ct/rabbitmq.sh | 54 +++++++++++++++++++++++-------------- install/rabbitmq-install.sh | 14 +++++----- 2 files changed, 40 insertions(+), 28 deletions(-) diff --git a/ct/rabbitmq.sh b/ct/rabbitmq.sh index 99dfb6cd4..7f0196b9a 100644 --- a/ct/rabbitmq.sh +++ b/ct/rabbitmq.sh @@ -20,26 +20,40 @@ color catch_errors function update_script() { - header_info - check_container_storage - check_container_resources - if [[ ! -d /etc/rabbitmq ]]; then - msg_error "No ${APP} Installation Found!" - exit - fi - msg_info "Stopping ${APP} Service" - systemctl stop rabbitmq-server - msg_ok "Stopped ${APP} Service" - - msg_info "Updating..." - $STD apt install --only-upgrade rabbitmq-server - msg_ok "Update Successfully" - - msg_info "Starting ${APP}" - systemctl start rabbitmq-server - msg_ok "Started ${APP}" - msg_ok "Updated Successfully" + header_info + check_container_storage + check_container_resources + if [[ ! -d /etc/rabbitmq ]]; then + msg_error "No ${APP} Installation Found!" exit + fi + if grep -q "dl.cloudsmith.io" /etc/apt/sources.list.d/rabbitmq.list; then + rm -f /etc/apt/sources.list.d/rabbitmq.list + cat </etc/apt/sources.list.d/rabbitmq.list +## Modern Erlang/OTP releases +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb1.rabbitmq.com/rabbitmq-erlang/debian/bookworm bookworm main +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb2.rabbitmq.com/rabbitmq-erlang/debian/bookworm bookworm main + +## Provides modern RabbitMQ releases +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb1.rabbitmq.com/rabbitmq-server/debian/bookworm bookworm main +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb2.rabbitmq.com/rabbitmq-server/debian/bookworm bookworm main +EOF + $STD apt-get update + fi + + msg_info "Stopping ${APP} Service" + systemctl stop rabbitmq-server + msg_ok "Stopped ${APP} Service" + + msg_info "Updating..." + $STD apt install --only-upgrade rabbitmq-server + msg_ok "Update Successfully" + + msg_info "Starting ${APP}" + systemctl start rabbitmq-server + msg_ok "Started ${APP}" + msg_ok "Updated Successfully" + exit } start @@ -49,4 +63,4 @@ description msg_ok "Completed Successfully!\n" echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}" echo -e "${INFO}${YW} Access it using the following URL:${CL}" -echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:15672${CL}" \ No newline at end of file +echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:15672${CL}" diff --git a/install/rabbitmq-install.sh b/install/rabbitmq-install.sh index 488f401b4..449ceaf9e 100644 --- a/install/rabbitmq-install.sh +++ b/install/rabbitmq-install.sh @@ -23,19 +23,17 @@ msg_ok "Installed Dependencies" msg_info "Adding RabbitMQ signing key" curl -fsSL "https://keys.openpgp.org/vks/v1/by-fingerprint/0A9AF2115F4687BD29803A206B73A36E6026DFCA" | gpg --dearmor >/usr/share/keyrings/com.rabbitmq.team.gpg -curl -fsSL "https://github.com/rabbitmq/signing-keys/releases/download/3.0/cloudsmith.rabbitmq-erlang.E495BB49CC4BBE5B.key" | gpg --dearmor >/usr/share/keyrings/rabbitmq.E495BB49CC4BBE5B.gpg -curl -fsSL "https://github.com/rabbitmq/signing-keys/releases/download/3.0/cloudsmith.rabbitmq-server.9F4587F226208342.key" | gpg --dearmor >/usr/share/keyrings/rabbitmq.9F4587F226208342.gpg msg_ok "Signing keys added" msg_info "Adding RabbitMQ repository" cat </etc/apt/sources.list.d/rabbitmq.list -## Provides modern Erlang/OTP releases from a Cloudsmith mirror -deb [signed-by=/usr/share/keyrings/rabbitmq.E495BB49CC4BBE5B.gpg] https://dl.cloudsmith.io/public/rabbitmq/rabbitmq-erlang/deb/debian $(lsb_release -cs) main -deb-src [signed-by=/usr/share/keyrings/rabbitmq.E495BB49CC4BBE5B.gpg] https://dl.cloudsmith.io/public/rabbitmq/rabbitmq-erlang/deb/debian $(lsb_release -cs) main +## Modern Erlang/OTP releases +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb1.rabbitmq.com/rabbitmq-erlang/debian/bookworm bookworm main +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb2.rabbitmq.com/rabbitmq-erlang/debian/bookworm bookworm main -## Provides RabbitMQ from a Cloudsmith mirror -deb [signed-by=/usr/share/keyrings/rabbitmq.9F4587F226208342.gpg] https://dl.cloudsmith.io/public/rabbitmq/rabbitmq-server/deb/debian $(lsb_release -cs) main -deb-src [signed-by=/usr/share/keyrings/rabbitmq.9F4587F226208342.gpg] https://dl.cloudsmith.io/public/rabbitmq/rabbitmq-server/deb/debian $(lsb_release -cs) main +## Provides modern RabbitMQ releases +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb1.rabbitmq.com/rabbitmq-server/debian/bookworm bookworm main +deb [arch=amd64 signed-by=/usr/share/keyrings/com.rabbitmq.team.gpg] https://deb2.rabbitmq.com/rabbitmq-server/debian/bookworm bookworm main EOF msg_ok "RabbitMQ repository added"