Fixing RabbitMQ Sources Repository

Tags: repository rabbitmq Ubuntu

The Error

Err:10 https://dl.bintray.com/rabbitmq-erlang/debian bionic InRelease                                                                                                                                 
  403  Forbidden [IP: 34.217.158.44 443]                                                                   
E: Failed to fetch https://dl.bintray.com/rabbitmq-erlang/debian/dists/bionic/InRelease  403  Forbidden [IP: 34.217.158.44 443]
E: The repository 'https://dl.bintray.com/rabbitmq-erlang/debian bionic InRelease' is no longer signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

The Fix

Seems to be related to the shutdown of Bintray sometime around April. So the first step is to delete my /etc/apt/sources.list.d/bintray.erlang.list file which contained deb https://dl.bintray.com/rabbitmq-erlang/debian bionic erlang-22.x.

Then I replace my original /etc/apt/sources.list.d/rabbitmq_rabbitmq-server.list which looked like this:

# this file was generated by packagecloud.io for
# the repository at https://packagecloud.io/rabbitmq/rabbitmq-server

deb https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ bionic main
deb-src https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ bionic main

To this:

## Provides modern Erlang/OTP releases
##
## "bionic" as distribution name should work for any reasonably recent Ubuntu or Debian release.
## See the release to distribution mapping table in RabbitMQ doc guides to learn more.
deb http://ppa.launchpad.net/rabbitmq/rabbitmq-erlang/ubuntu bionic main
deb-src http://ppa.launchpad.net/rabbitmq/rabbitmq-erlang/ubuntu bionic main

## Provides RabbitMQ
##
## "bionic" as distribution name should work for any reasonably recent Ubuntu or Debian release.
## See the release to distribution mapping table in RabbitMQ doc guides to learn more.
deb https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ bionic main
deb-src https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu/ bionic main

Then update the keys:

## Team RabbitMQ's main signing key
sudo apt-key adv --keyserver "hkps://keys.openpgp.org" --recv-keys "0x0A9AF2115F4687BD29803A206B73A36E6026DFCA"
## Launchpad PPA that provides modern Erlang releases
sudo apt-key adv --keyserver "keyserver.ubuntu.com" --recv-keys "F77F1EDA57EBB1CC"
## PackageCloud RabbitMQ repository
curl -1sLf 'https://packagecloud.io/rabbitmq/rabbitmq-server/gpgkey' | sudo apt-key add -

Then a simple:

sudo apt-get update -y
sudo apt-get upgrade -y

And we're good!