I have Debian Buster on VirtualBox, I install these open keyrings because I will install PHP.


I doing

#apt update

#apt install ca-certificates apt-transport-https lsb-release curl unzip -y

Now install OpenPGP Key distribution, how Debian to tell,

wget -O /usr/share/keyrings/apt.gpg https://packages.sury.org/php/apt.gpg

then doing

#apt update

#apt install libapache2-mod-php7.3

#apt install apache2 -y

#apt install php7.3 php7.3-cli php7.3-curl php7.3-gd php7.3-intl php7.3-json php7.3-mbstring php7.3-mysql php7.3-opcache php7.3-readline php7.3-xml php7.3-xsl php7.3-zip php7.3-bz2 libapache2-mod-php7.3 -y

PHP and Apache is installed and all working gut, my question is, I to need to add a signed File to /etc/apt/sources.list.d/apt.gpg how Debian tell here for later Update it, I trying to do it with nano /etc/apt/sources.list.d/php.list and add these Line on it,

deb [signed-by=/usr/share/keyrings/apt.gpg]  https://packages.sury.org/php/dists/buster/Release 

but when give apt update, come a warning that to say which my sources.list can't all Download.

Can Please someone answer me on this question, Thanks!


My question;

I to need to add a signed File to /etc/apt/sources.list.d/apt.gpg as Debian here to say.

I found the solution on how to does it..

I to do how https://packages.sury.org/php/README.txt to say

${SUDO} apt-get -y install apt-transport-https lsb-release ca-certificates

${SUDO} wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg

${SUDO} sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list'

${SUDO} apt-get update

With this command create the /etc/apt/sources.list.d/php.list File and add the keyrings to sources.list.d as Debian here to say.

# sh -c 'echo "deb [signed-by=/usr/share/keyrings/apt.gpg] https://packages.sury.org/php/ $(lsb_release -sc) main" | tee /etc/apt/sources.list.d/php.list'

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.