2022-05-24

Plex repository on Jammy Jellyfish

The latest ubuntu depreciates apt-key so we need to do a bit of readjusting to get apt to play nice with custom repos like Plex. As far as I understand this is the proper way to do this vs just dropping the plexmediaserver.gpg into trusted.gpg.d which could allow the new key to sign for other repos beyong just the one we want to use it for.

Step 1: Get the key and convert it, drop it in a shared keyring folder.

$ curl -s https://downloads.plex.tv/plex-keys/PlexSign.key |\
sudo gpg --no-default-keyring --keyring gnupg-ring:/usr/share/keyrings/plexmediaserver.gpg --import

Step 2: Make the public key file readable by all users (if you want.)

$ sudo chmod 644 /usr/share/keyrings/plexmediaserver.gpg

Step 3: Update sources.list.d with our new repo and its key

$ echo "deb [signed-by=/usr/share/keyrings/plexmediaserver.gpg] https://downloads.plex.tv/repo/deb public main" |\
sudo tee /etc/apt/sources.list.d/plexmediaserver.list

Step 4: Profit.

 

Thanks to: https://stackoverflow.com/questions/68992799/warning-apt-key-is-deprecated-manage-keyring-files-in-trusted-gpg-d-instead

https://support.plex.tv/articles/235974187-enable-repository-updating-for-supported-linux-server-distributions/

https://linuxize.com/post/how-to-install-plex-media-server-on-ubuntu-20-04/