Switch to elasticsearch 7.x and build lma-build-prep early

There have been frequent 404 errors attempting to access the
artifacts.elastic.co archive for 5.x.

Change-Id: I04529e8d5584e006c090e790e9903592609343ee
This commit is contained in:
Corey Bryant 2021-03-02 08:51:54 -05:00
parent 0ae9adef3e
commit 07108d1d38
1 changed files with 5 additions and 3 deletions

View File

@ -646,6 +646,8 @@ parts:
# Allows us to fetch things such as updated libvirt.
uca-sources:
plugin: nil
after:
- lma-build-prep
build-packages:
- ubuntu-cloud-keyring
- software-properties-common
@ -1536,7 +1538,7 @@ parts:
filebeat:
plugin: dump
source: ./snap-wrappers/filebeat
after: [ lma-build-prep, qemu, libvirt ]
after: [ lma-build-prep ]
stage-packages: [ filebeat ]
organize:
filebeat: bin/filebeat
@ -1556,7 +1558,7 @@ parts:
telegraf: bin/telegraf
# we use autotools plugin here because it brings git, make
# otherwise we'd have to add respective packages
after: [ lma-build-prep, qemu, libvirt ]
after: [ lma-build-prep ]
# See https://forum.snapcraft.io/t/patchelf-broke-my-binary/4928
# and https://bugs.launchpad.net/snapcraft/+bug/1753995
build-attributes: [no-patchelf]
@ -1571,7 +1573,7 @@ parts:
cat $SNAPCRAFT_PROJECT_DIR/filebeat.pgp.key | apt-key add -
cat $SNAPCRAFT_PROJECT_DIR/telegraf.pgp.key | apt-key add -
apt-get install apt-transport-https
echo 'deb https://artifacts.elastic.co/packages/5.x/apt stable main' > /etc/apt/sources.list.d/elastic-5.x.list
echo 'deb https://artifacts.elastic.co/packages/7.x/apt stable main' > /etc/apt/sources.list.d/elastic-7.x.list
echo 'deb http://ppa.launchpad.net/telegraf-devs/ppa/ubuntu bionic main' > /etc/apt/sources.list.d/telegraf.x.list
# this needs to be re-worked in order to be built in-place
echo 'deb http://ppa.launchpad.net/nikolay.vinogradov/nrpe-root/ubuntu bionic main' > /etc/apt/sources.list.d/nrpe-root.list