Kibana v8.6.0 docker image build fails

Hello,
I'm attempting to build a Kibana Docker image from the source code, specifically for version 8.6.0. However, I'm encountering an error. I followed the same procedure for this version a couple of months ago but did not face this issue at that time.
here is the error:

info [  kibana  ] Downloading Elastic GPG key for Fleet
   │ info Downloading Elastic GPG key from https://artifacts.elastic.co/GPG-KEY-elasticsearch to /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ debg [1/3] Attempting download of https://artifacts.elastic.co/GPG-KEY-elasticsearch sha512
   │ debg Downloaded 1794 bytes to /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ debg Download failed: Downloaded checksum 62a567354286deb02baf5fc6b82ddf6c7067898723463da9ae65b132b8c6d6f064b2874e390885682376228eed166c1c82fe7f11f6c9a69f0c157029c548fa3d does not match the expected sha512 checksum.
   │ debg Deleting downloaded data at /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ info Retrying in 5 seconds
   │ debg [2/3] Attempting download of https://artifacts.elastic.co/GPG-KEY-elasticsearch sha512
   │ debg Downloaded 1794 bytes to /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ debg Download failed: Downloaded checksum 62a567354286deb02baf5fc6b82ddf6c7067898723463da9ae65b132b8c6d6f064b2874e390885682376228eed166c1c82fe7f11f6c9a69f0c157029c548fa3d does not match the expected sha512 checksum.
   │ debg Deleting downloaded data at /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ info Retrying in 10 seconds
   │ debg [3/3] Attempting download of https://artifacts.elastic.co/GPG-KEY-elasticsearch sha512
   │ debg Downloaded 1794 bytes to /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ debg Download failed: Downloaded checksum 62a567354286deb02baf5fc6b82ddf6c7067898723463da9ae65b132b8c6d6f064b2874e390885682376228eed166c1c82fe7f11f6c9a69f0c157029c548fa3d does not match the expected sha512 checksum.
   │ debg Deleting downloaded data at /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ERROR Error downloading Elastic GPG key from https://artifacts.elastic.co/GPG-KEY-elasticsearch to /home/currentuser/temp_repo/kibana/build/kibana/x-pack/plugins/fleet/target/keys/GPG-KEY-elasticsearch
   │ERROR failure 15 sec
   │ERROR Error: Downloaded checksum 62a567354286deb02baf5fc6b82ddf6c7067898723463da9ae65b132b8c6d6f064b2874e390885682376228eed166c1c82fe7f11f6c9a69f0c157029c548fa3d does not match the expected sha512 checksum.
   │          at downloadToDisk (/home/currentuser/temp_repo/kibana/src/dev/build/lib/download.ts:114:17)
   │          at runMicrotasks (<anonymous>)
   │          at processTicksAndRejections (node:internal/process/task_queues:96:5)
   │          at Object.run (/home/currentuser/temp_repo/kibana/src/dev/build/tasks/fleet_download_elastic_gpg_key.ts:26:7)
   │          at /home/currentuser/temp_repo/kibana/src/dev/build/lib/runner.ts:47:11
   │          at /home/currentuser/temp_repo/kibana/node_modules/@kbn/tooling-log/target_node/src/tooling_log.js:63:18
   │          at execTask (/home/currentuser/temp_repo/kibana/src/dev/build/lib/runner.ts:37:7)
   │          at run (/home/currentuser/temp_repo/kibana/src/dev/build/lib/runner.ts:78:9)
   │          at buildDistributables (/home/currentuser/temp_repo/kibana/src/dev/build/build_distributables.ts:95:5)

I used the following command: node scripts/build --docker-images. This works for version 8.0, but same error for 8.6 and 8.7 (only tried on these two).

how can I resolve this error?
Thank you.

Hi,

Manually download the GPG key from the URL in the error message and verify its integrity. If the key is valid, the issue might be with the hardcoded checksum in the Kibana source code.

Regards

Hi,
I got the following output using gpg tool:
pub rsa2048/D27D666CD88E42B4 2013-09-16 [SC]
Key fingerprint = 4609 5ACC 8548 582C 1A26 99A9 D27D 666C D88E 42B4
uid Elasticsearch (Elasticsearch Signing Key) dev_ops@elasticsearch.org
sub rsa2048/AB6B7FCB60D31954 2013-09-16 [E]

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.