Merge ~ubuntu-docker-images/prometheus-alertmanager-snap:update-to-version-0.21.0 into ~canonical-is-sa/prometheus-alertmanager-snap:master

Proposed by Lucas Kanashiro
Status: Merged
Approved by: Tom Haddon
Approved revision: d24bee11830742901e94b291c500c2f06f52b9c7
Merge reported by: Tom Haddon
Merged at revision: d24bee11830742901e94b291c500c2f06f52b9c7
Proposed branch: ~ubuntu-docker-images/prometheus-alertmanager-snap:update-to-version-0.21.0
Merge into: ~canonical-is-sa/prometheus-alertmanager-snap:master
Diff against target: 59 lines (+17/-13)
1 file modified
snapcraft.yaml (+17/-13)
Reviewer Review Type Date Requested Status
Tom Haddon Approve
Haw Loeung +1 Approve
Jeremy Lounder (community) Approve
Junien F Approve
Canonical IS Reviewers Pending
Review via email: mp+389028@code.launchpad.net

Commit message

Update to version 0.21.0 (LP: #1883945)

Description of the change

Update prometheus-alertmanager snap to the latest upstream version (0.21.0). The Server team is working on prometheus-alertmanager for the LMA stack we want to support, and we noticed the prometheus-alertmanager snap is quite outdated (there is also a request for update in LP #1883945). We think we can work together with the IS team to provide and up-to-dated snap. A summary of the proposed changes:

- Update to version 0.21.0
- Build the snap based on core18
- Build the snap for different architectures: amd64, arm64, ppc64el and s390x
- Rewrite part of 'alertmanager' parts section
  + Run a set of upstream tests during build time

I have personally played with it locally and AFAICS it looks good, works well. I also built the snap in all 4 architectures here:

https://code.launchpad.net/~lucaskanashiro/+snap/prometheus-alertmanager

Thanks for considering those changes, feedback is appreciated.

To post a comment you must log in.
Revision history for this message
Lucas Kanashiro (lucaskanashiro) wrote :

Any feedback?

Revision history for this message
Tom Haddon (mthaddon) wrote :

I suspect there should be someone else involved in the review of this, as jldev owns the snap. I'll reach out to him and confirm one way or the other.

Revision history for this message
Junien F (axino) wrote :

LGTM (with just a very minor issue), thanks a lot for doing that !

review: Approve
Revision history for this message
Tom Haddon (mthaddon) wrote :

One other minor comment inline

Revision history for this message
Lucas Kanashiro (lucaskanashiro) wrote :

Thanks again Junien and Tom! Comments addressed and up for review again.

Revision history for this message
Lucas Kanashiro (lucaskanashiro) wrote :

Is there something blocking this MP?

Revision history for this message
Junien F (axino) wrote :

llama charmers approval I would say

Revision history for this message
Jeremy Lounder (jldev) :
review: Approve
Revision history for this message
Haw Loeung (hloeung) wrote :

LGTM

review: Approve (+1)
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
Tom Haddon (mthaddon) wrote :

LGTM

review: Approve
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Failed to merge change (no changes to merge), setting status to needs review.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/snapcraft.yaml b/snapcraft.yaml
2index d343c22..5f8a4db 100644
3--- a/snapcraft.yaml
4+++ b/snapcraft.yaml
5@@ -1,10 +1,17 @@
6 name: prometheus-alertmanager
7-version: 0.15.2
8+version: 0.21.0
9+base: core18
10 grade: stable
11 summary: The Prometheus alertmanager
12 description: |
13 The Alertmanager handles alerts sent by client applications such as the Prometheus server. It takes care of deduplicating, grouping, and routing them to the correct receiver integration such as email, PagerDuty, or OpsGenie. It also takes care of silencing and inhibition of alerts.
14 confinement: strict
15+architectures:
16+ - build-on: amd64
17+ - build-on: arm64
18+ - build-on: ppc64el
19+ - build-on: s390x
20+
21 apps:
22 alertmanager:
23 command: 'bin/prometheus-alertmanager.wrapper'
24@@ -14,26 +21,23 @@ apps:
25 command: 'bin/amtool'
26 plugs: [network]
27 parts:
28- go:
29- source-tag: go1.9
30 alertmanager:
31- after: [go]
32 plugin: go
33+ go-channel: 1.14/stable
34 source: https://github.com/prometheus/alertmanager.git
35- source-tag: v0.15.2
36+ source-tag: v${SNAPCRAFT_PROJECT_VERSION}
37 go-importpath: github.com/prometheus/alertmanager
38- build: |
39- export "GOPATH=$PWD/../go"
40- cd ../go/src/github.com/prometheus/alertmanager/
41+ build-packages: [build-essential, curl, make]
42+ override-build: |
43 make build
44- install: |
45- mkdir $SNAPCRAFT_PART_INSTALL/bin
46- cp -p $SNAPCRAFT_PART_INSTALL/../src/alertmanager $SNAPCRAFT_PART_INSTALL/bin/
47- cp -p $SNAPCRAFT_PART_INSTALL/../src/amtool $SNAPCRAFT_PART_INSTALL/bin/
48+ make common-test-short
49+ mkdir -p $SNAPCRAFT_PART_INSTALL/bin
50+ cp -p $SNAPCRAFT_PART_BUILD/alertmanager $SNAPCRAFT_PART_INSTALL/bin/
51+ cp -p $SNAPCRAFT_PART_BUILD/amtool $SNAPCRAFT_PART_INSTALL/bin/
52 example-config:
53 plugin: dump
54 source: https://github.com/prometheus/alertmanager.git
55- source-tag: v0.15.2
56+ source-tag: v${SNAPCRAFT_PROJECT_VERSION}
57 organize:
58 doc/examples/simple.yml: etc/prometheus/alertmanager.yml.example
59 prime:

Subscribers

People subscribed via source and target branches