Merge ~ubuntu-docker-images/ubuntu-docker-images/+git/grafana:use-snap-architecture-21.04 into ~ubuntu-docker-images/ubuntu-docker-images/+git/grafana:7.4-21.04
Proposed by
Sergio Durigan Junior
Status: | Merged |
---|---|
Merged at revision: | 3902b0d6978744d01481a7b9015414d6a1869d03 |
Proposed branch: | ~ubuntu-docker-images/ubuntu-docker-images/+git/grafana:use-snap-architecture-21.04 |
Merge into: | ~ubuntu-docker-images/ubuntu-docker-images/+git/grafana:7.4-21.04 |
Diff against target: |
12 lines (+1/-1) 1 file modified
Dockerfile (+1/-1) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Athos Ribeiro | Approve | ||
Bryce Harrington | Pending | ||
Canonical Server | Pending | ||
Review via email:
|
Description of the change
This MP fixes a problem that is affecting snap-based images.
Because we don't explicitly specify an architecture when querying snapcraft for the snap download URL, we end up always getting the amd64 snap, even on non-amd64 architectures. This means that that we install amd64 binaries in the non-amd64 OCI images, which end up making them unusable.
The fix here is to specify the architecture by setting the X-Ubuntu-
I tested this on a ppc64el machine and it works.
To post a comment you must log in.
Hi Sergio, Thanks for this MP!
LGTM
This was tested by running the new RUN command locally and verifying the snap fs was sane. Then, I proceeded to substitute the new dpkg command by different architectures to verify that the contents of the snap carried the contents for the correct arch.
$file x86/bin/ grafana- server grafana- server: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ ld-linux- x86-64. so.2, BuildID[ sha1]=99c08d5c4 39e74e3dbaeb100 50deaa255aa4a90 2, for GNU/Linux 3.2.0, not stripped
x86/bin/
$ file arm/bin/ grafana- server grafana- server: ELF 64-bit LSB executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /lib/ld- linux-aarch64. so.1, BuildID[ sha1]=3acb6dec7 0233f669cde30e7 56feb02fea8e74d 4, for GNU/Linux 3.7.0, not stripped
arm/bin/