Merge ~sbeattie/qa-regression-testing:lpci-apply_updates_before_testing into qa-regression-testing:master

Proposed by Steve Beattie
Status: Merged
Merged at revision: d1402ed74e41ec5d03968e5f0026a28340459397
Proposed branch: ~sbeattie/qa-regression-testing:lpci-apply_updates_before_testing
Merge into: qa-regression-testing:master
Diff against target: 131 lines (+29/-1)
1 file modified
.launchpad.yaml (+29/-1)
Reviewer Review Type Date Requested Status
Emilia Torino Approve
Review via email: mp+465105@code.launchpad.net

Commit message

lpci: run `apt upgrade` before exercising tests

The automatic runs of qa-regression-testing were failing in
the util-linux tests, even though the most recent util-linux
security update had been published to the ubuntu archive, because
lpci explicitly does not apply updates to the spawned test
environments that the jobs are run in. Furthermore, there is no
specific job configuration to tell lpci to apply updates first in
https://lpci.readthedocs.io/en/latest/configuration.html#job-definitions

To work around this limitation, add a run-before step in each job to run
`apt upgrade` so that the most up-to-date version of a package is tested
against.

An open question here is whether it would be more appropriate to use
`dist-upgrade` rather than a simple `upgrade`

Bug: https://bugs.launchpad.net/lpci/+bug/2063880

To post a comment you must log in.
Revision history for this message
Emilia Torino (emitorino) wrote :

Thanks for fixing this Steve.

I see this might need to be added every time a new job is added, so wondering how to make sure we don't forget. I check but it seems there it seems there is no such "top-level" (not per job) configuration: https://lpci.readthedocs.io/en/latest/configuration.html#top-level-configuration.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/.launchpad.yaml b/.launchpad.yaml
2index 43beb1a..a32b91d 100644
3--- a/.launchpad.yaml
4+++ b/.launchpad.yaml
5@@ -26,6 +26,8 @@ jobs:
6 architectures: amd64
7 packages:
8 - sudo
9+ run-before: |
10+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
11 run: |
12 ./lpcraft-runner imagemagick
13
14@@ -39,6 +41,8 @@ jobs:
15 architectures: amd64
16 packages:
17 - sudo
18+ run-before: |
19+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
20 run: |
21 ./lpcraft-runner gcc-security
22
23@@ -52,6 +56,8 @@ jobs:
24 architectures: amd64
25 packages:
26 - sudo
27+ run-before: |
28+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
29 run: |
30 ./lpcraft-runner glibc
31
32@@ -65,6 +71,8 @@ jobs:
33 architectures: amd64
34 packages:
35 - sudo
36+ run-before: |
37+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
38 run: |
39 ./lpcraft-runner glibc-security
40
41@@ -78,6 +86,8 @@ jobs:
42 architectures: amd64
43 packages:
44 - sudo
45+ run-before: |
46+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
47 run: |
48 ./lpcraft-runner sudo
49
50@@ -91,6 +101,8 @@ jobs:
51 architectures: amd64
52 packages:
53 - sudo
54+ run-before: |
55+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
56 run: |
57 ./lpcraft-runner gnupg
58
59@@ -104,6 +116,8 @@ jobs:
60 architectures: amd64
61 packages:
62 - sudo
63+ run-before: |
64+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
65 run: |
66 ./lpcraft-runner git
67
68@@ -117,6 +131,8 @@ jobs:
69 architectures: amd64
70 packages:
71 - sudo
72+ run-before: |
73+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
74 run: |
75 ./lpcraft-runner ghostscript
76
77@@ -130,6 +146,8 @@ jobs:
78 architectures: amd64
79 packages:
80 - sudo
81+ run-before: |
82+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
83 run: |
84 ./lpcraft-runner busybox
85
86@@ -143,6 +161,8 @@ jobs:
87 architectures: amd64
88 packages:
89 - sudo
90+ run-before: |
91+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
92 run: |
93 ./lpcraft-runner coreutils
94
95@@ -156,6 +176,8 @@ jobs:
96 architectures: amd64
97 packages:
98 - sudo
99+ run-before: |
100+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
101 run: |
102 ./lpcraft-runner util-linux
103
104@@ -169,6 +191,8 @@ jobs:
105 architectures: amd64
106 packages:
107 - sudo
108+ run-before: |
109+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
110 run: |
111 ./lpcraft-runner ecdsautils
112
113@@ -182,6 +206,8 @@ jobs:
114 architectures: amd64
115 packages:
116 - sudo
117+ run-before: |
118+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
119 run: |
120 ./lpcraft-runner python-urllib3
121
122@@ -196,5 +222,7 @@ jobs:
123 # architectures: amd64
124 packages:
125 - sudo
126+ run-before: |
127+ DEBIAN_FRONTEND=noninteractive apt upgrade --assume-yes
128 run: |
129- ./lpcraft-runner amanda
130\ No newline at end of file
131+ ./lpcraft-runner amanda

Subscribers

People subscribed via source and target branches