[GH-ISSUE #406] gpg: keyserver receive failed: Connection timed out #209

Closed
opened 2026-02-26 10:30:59 +03:00 by kerem · 2 comments
Owner

Originally created by @Dnhatsave on GitHub (Feb 10, 2022).
Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/406

Hi Everyone,

When i run docker-compose build it show that Error:

Warning: apt-key output should not be parsed (stdout is not a terminal) Executing: /tmp/apt-key-gpghome.q5N7wSp5bQ/gpg.1.sh --keyserver keyserver.ubuntu.com --recv-keys 0x8320ca65cb2de8e5 gpg: keyserver receive failed: Connection timed out ERROR: Service 'docker-documentserver-master_onlyoffice-documentserver' failed to build: The command '/bin/sh -c echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d && apt-get -y update && apt-get -yq install wget apt-transport-https gnupg locales && apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 0x8320ca65cb2de8e5 && locale-gen en_US.UTF-8 && echo ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true | debconf-set-selections && apt-get -yq install adduser apt-utils bomstrip certbot curl gconf-service htop libasound2 libboost-regex-dev libcairo2 libcurl3-gnutls libcurl4 libgtk-3-0 libnspr4 libnss3 libstdc++6 libxml2 libxss1 libxtst6 mysql-client nano net-tools netcat-openbsd nginx-extras postgresql postgresql-client pwgen rabbitmq-server redis-server software-properties-common sudo supervisor ttf-mscorefonts-installer xvfb zlib1g && if [ $(ls -l /usr/share/fonts/truetype/msttcorefonts | wc -l) -ne 61 ]; then echo 'msttcorefonts failed to download'; exit 1; fi && echo "SERVER_ADDITIONAL_ERL_ARGS=\"+S 1:1\"" | tee -a /etc/rabbitmq/rabbitmq-env.conf && sed -i "s/bind .*/bind 127.0.0.1/g" /etc/redis/redis.conf && sed 's|\(application\/zip.*\)|\1\n application\/wasm wasm;|' -i /etc/nginx/mime.types && pg_conftool $PG_VERSION main set listen_addresses 'localhost' && service postgresql restart && sudo -u postgres psql -c "CREATE DATABASE $ONLYOFFICE_VALUE;" && sudo -u postgres psql -c "CREATE USER $ONLYOFFICE_VALUE WITH password '$ONLYOFFICE_VALUE';" && sudo -u postgres psql -c "GRANT ALL privileges ON DATABASE $ONLYOFFICE_VALUE TO $ONLYOFFICE_VALUE;" && service postgresql stop && service redis-server stop && service rabbitmq-server stop && service supervisor stop && service nginx stop && rm -rf /var/lib/apt/lists/*' returned a non-zero code: 2

I think the link of keyserver its broken, is there an alternative link to download the gpg:keyserver??

Originally created by @Dnhatsave on GitHub (Feb 10, 2022). Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/406 Hi Everyone, When i run docker-compose build it show that Error: `Warning: apt-key output should not be parsed (stdout is not a terminal) Executing: /tmp/apt-key-gpghome.q5N7wSp5bQ/gpg.1.sh --keyserver keyserver.ubuntu.com --recv-keys 0x8320ca65cb2de8e5 gpg: keyserver receive failed: Connection timed out ERROR: Service 'docker-documentserver-master_onlyoffice-documentserver' failed to build: The command '/bin/sh -c echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d && apt-get -y update && apt-get -yq install wget apt-transport-https gnupg locales && apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 0x8320ca65cb2de8e5 && locale-gen en_US.UTF-8 && echo ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true | debconf-set-selections && apt-get -yq install adduser apt-utils bomstrip certbot curl gconf-service htop libasound2 libboost-regex-dev libcairo2 libcurl3-gnutls libcurl4 libgtk-3-0 libnspr4 libnss3 libstdc++6 libxml2 libxss1 libxtst6 mysql-client nano net-tools netcat-openbsd nginx-extras postgresql postgresql-client pwgen rabbitmq-server redis-server software-properties-common sudo supervisor ttf-mscorefonts-installer xvfb zlib1g && if [ $(ls -l /usr/share/fonts/truetype/msttcorefonts | wc -l) -ne 61 ]; then echo 'msttcorefonts failed to download'; exit 1; fi && echo "SERVER_ADDITIONAL_ERL_ARGS=\"+S 1:1\"" | tee -a /etc/rabbitmq/rabbitmq-env.conf && sed -i "s/bind .*/bind 127.0.0.1/g" /etc/redis/redis.conf && sed 's|\(application\/zip.*\)|\1\n application\/wasm wasm;|' -i /etc/nginx/mime.types && pg_conftool $PG_VERSION main set listen_addresses 'localhost' && service postgresql restart && sudo -u postgres psql -c "CREATE DATABASE $ONLYOFFICE_VALUE;" && sudo -u postgres psql -c "CREATE USER $ONLYOFFICE_VALUE WITH password '$ONLYOFFICE_VALUE';" && sudo -u postgres psql -c "GRANT ALL privileges ON DATABASE $ONLYOFFICE_VALUE TO $ONLYOFFICE_VALUE;" && service postgresql stop && service redis-server stop && service rabbitmq-server stop && service supervisor stop && service nginx stop && rm -rf /var/lib/apt/lists/*' returned a non-zero code: 2 ` I think the link of keyserver its broken, is there an alternative link to download the gpg:keyserver??
kerem closed this issue 2026-02-26 10:30:59 +03:00
Author
Owner

@ShockwaveNN commented on GitHub (Feb 10, 2022):

I think maybe it may be blocked/banned or something like this in your country

Did you try to connect with some kind VPN?

I think any alternative will be fine, first page in google showed me that

<!-- gh-comment-id:1034816920 --> @ShockwaveNN commented on GitHub (Feb 10, 2022): I think maybe it may be blocked/banned or something like this in your country Did you try to connect with some kind VPN? I think any alternative will be fine, first page in google showed me [that](https://blog.emilburzo.com/2015/10/work-around-for-when-keyserverubuntucom/)
Author
Owner

@Dnhatsave commented on GitHub (Feb 10, 2022):

Thanks for rapid response @ShockwaveNN ,

I've follow the steps in link below:
https://ubuntu.com/tutorials/how-to-install-onlyoffice-server-on-ubuntu#2-installation

in my country the URL hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 works fine for me.

<!-- gh-comment-id:1034859046 --> @Dnhatsave commented on GitHub (Feb 10, 2022): Thanks for rapid response @ShockwaveNN , I've follow the steps in link below: https://ubuntu.com/tutorials/how-to-install-onlyoffice-server-on-ubuntu#2-installation in my country the URL hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5 works fine for me.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Docker-DocumentServer-ONLYOFFICE#209
No description provided.