[R-sig-Debian] Solution to apt-key depreciation

Carl Delfin c@r|de|||n @end|ng |rom pm@me
Wed Mar 17 16:52:17 CET 2021


Michael,

Sounds great!

If it's any help, I put my solution in a bash script:

#!/bin/bash
KEY=/usr/local/share/keyrings/marutter.key

if [ -f "$KEY" ]; then
  echo "$KEY already exists"
  sudo apt install -y r-base
else
  wget -q -O marutter.key "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0xe298a3a825c0d65dfd57cbb651716619e084dab9"
  if ! file marutter.key | grep -q "PGP public key"; then
    echo "marutter.key does not appear to be a valid PGP key - aborting!"
    exit 1
  else
    sudo mkdir -p /usr/local/share/keyrings/
    sudo mv marutter.key /usr/local/share/keyrings/
    echo "deb [signed-by=/usr/local/share/keyrings/marutter.key] https://cloud.r-project.org/bin/linux/ubuntu groovy-cran40/" | sudo tee -a /etc/apt/sources.list
 fi
 sudo apt install -y r-base
fi

Nothing fancy by any means, but it works and could perhaps be useful.

Cheers,
Carl

Sent with ProtonMail Secure Email.

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐

On Wednesday, March 17th, 2021 at 16:04, Michael Rutter <marutter using gmail.com> wrote:

> On 3/17/21 7:27 AM, Carl Delfin wrote:
>
> > Hi everyone,
> >
> > Since apt-key will be deprecated in future releases of Debian (https://manpages.debian.org/testing/apt/apt-key.8.en.html), I recently got around to figuring out how to properly import Michael Rutter's key, based on this answer over at askubuntu: https://askubuntu.com/a/1307181.
> >
> > Perhaps something along those lines should be added to the README at https://cran.r-project.org/bin/linux/ubuntu/fullREADME.html?
> >
> > Cheers,
> >
> > Carl
>
> Carl,
>
> Thank you. I need to read these posts over to see if the instructions
>
> can be condensed, but this is very helpful.
>
> Michael
>
> > Sent with ProtonMail Secure Email.
> >
> > [[alternative HTML version deleted]]
> >
> > R-SIG-Debian mailing list
> >
> > R-SIG-Debian using r-project.org
> >
> > https://stat.ethz.ch/mailman/listinfo/r-sig-debian
>
> R-SIG-Debian mailing list
>
> R-SIG-Debian using r-project.org
>
> https://stat.ethz.ch/mailman/listinfo/r-sig-debian



More information about the R-SIG-Debian mailing list