This is an automated email from the ASF dual-hosted git repository.

potiuk pushed a commit to branch v1-10-test
in repository https://gitbox.apache.org/repos/asf/airflow.git

commit b062b9259b81ba9c042a523f5454beb366e134ce
Author: J. Daniel Medeiros <[email protected]>
AuthorDate: Thu Nov 5 15:32:39 2020 -0100

    Update install_mysql.sh (#12101)
    
    After Debian 9 and according to the manual 
https://manpages.debian.org/stretch/apt/apt-key.8.en.html, after Debian 9  
instead of using "apt-key add" a keyring should be placed directly in the 
/etc/apt/trusted.gpg.d/ directory with a descriptive name and either "gpg" or 
"asc" as file extension. Also added better redirection on the apt-key list 
command.
    
    (cherry picked from commit ded3dbbff0c8e4fabcee62a677394dec0db1aa45)
---
 scripts/docker/install_mysql.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/docker/install_mysql.sh b/scripts/docker/install_mysql.sh
index 1ddc76b..0fbb1da 100755
--- a/scripts/docker/install_mysql.sh
+++ b/scripts/docker/install_mysql.sh
@@ -46,10 +46,10 @@ if [[ ${INSTALL_MYSQL_CLIENT:="true"} == "true" ]]; then
         gpg --keyserver "${keyserver}" --recv-keys "${KEY}" && break
     done
     set -e
-    gpg --export "${KEY}" | apt-key add -
+    gpg --export "${KEY}" > /etc/apt/trusted.gpg.d/mysql.gpg
     gpgconf --kill all
     rm -rf "${GNUPGHOME}"
-    apt-key list > /dev/null
+    apt-key list > /dev/null 2>&1
     echo "deb http://repo.mysql.com/apt/debian/ buster mysql-5.7" | tee -a 
/etc/apt/sources.list.d/mysql.list
     apt-get update
     apt-get install --no-install-recommends -y "${packages[@]}"

Reply via email to