Merge ~saviq/jenkaas-jobs:add-jenkaas-tools into jenkaas-jobs:master

Proposed by Michał Sawicz
Status: Merged
Merged at revision: 1067f041093823b0348c795dbcebf9da0f6bf1d2
Proposed branch: ~saviq/jenkaas-jobs:add-jenkaas-tools
Merge into: jenkaas-jobs:master
Diff against target: 106 lines (+8/-36)
5 files modified
jenkaas_jobs/yaml/prepare/prepare-0-install.sh (+2/-0)
jenkaas_jobs/yaml/prepare/prepare-1-sbuild.sh (+2/-9)
jenkaas_jobs/yaml/prepare/prepare-1-sbuild.yaml (+0/-8)
tests/fixtures/prepare/prepare-0-install.xml (+2/-0)
tests/fixtures/prepare/prepare-1-sbuild.xml (+2/-19)
Reviewer Review Type Date Requested Status
Olivier Tilloy (community) Approve
Review via email: mp+304745@code.launchpad.net

Commit message

Add ppa:jenkaas-hackers/tools to slaves

We now need new sbuild, we'll probably need more tools as we go.

NOTE: you need to run the prepare-0-install and maintain-0-upgrade
jobs on all build slaves to make this change work.

To post a comment you must log in.
Revision history for this message
Olivier Tilloy (osomon) wrote :

LGTM and tested on the system-apps jenkaas instance.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/jenkaas_jobs/yaml/prepare/prepare-0-install.sh b/jenkaas_jobs/yaml/prepare/prepare-0-install.sh
2index 24a2294..ba408c2 100644
3--- a/jenkaas_jobs/yaml/prepare/prepare-0-install.sh
4+++ b/jenkaas_jobs/yaml/prepare/prepare-0-install.sh
5@@ -10,6 +10,8 @@ sudo apt-get install --yes \
6
7 # build tools as used in Launchpad
8 sudo add-apt-repository --yes ppa:launchpad/buildd-staging
9+sudo add-apt-repository --yes ppa:jenkaas-hackers/tools
10+
11 # backported tools (e.g. autopkgtest)
12 if [[ "amd64 i386" == *`dpkg-architecture -qDEB_HOST_ARCH`* ]]; then
13 sudo add-apt-repository --yes "deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse"
14diff --git a/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.sh b/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.sh
15index 2c9bb1c..af68984 100644
16--- a/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.sh
17+++ b/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.sh
18@@ -12,15 +12,8 @@ if ! ( id | fgrep -q '(sbuild)' ); then
19 # need to restart jenkins-slave if jenkins isn't in sbuild group yet
20 sudo initctl restart --no-wait jenkins-slave
21 else
22- # copy the public key file
23- [ -f keys/sbuild-key.pub ] && sudo cp keys/sbuild-key.pub /var/lib/sbuild/apt-keys
24- [ -f keys/sbuild-key.sec ] && sudo mv keys/sbuild-key.sec /var/lib/sbuild/apt-keys
25-
26- if ! [ -f /var/lib/sbuild/apt-keys/sbuild-key.pub -a -f /var/lib/sbuild/apt-keys/sbuild-key.sec ]; then
27- echo "ERROR: You need to upload the sbuild archive keypair"
28-
29- exit 1
30- fi
31+ # remove the keys, if any - new sbuild doesn't require them
32+ sudo rm -Rf /var/lib/sbuild/apt-keys
33
34 # prepare shared ccache directory
35 ccdir=/var/cache/ccache-sbuild
36diff --git a/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.yaml b/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.yaml
37index 5b9bc11..d77a887 100644
38--- a/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.yaml
39+++ b/jenkaas_jobs/yaml/prepare/prepare-1-sbuild.yaml
40@@ -15,14 +15,6 @@
41 - matrix-combinations:
42 name: configurations
43 description: Which slaves to run these steps on
44- - file:
45- name: keys/sbuild-key.pub
46- description: Public key file for sbuild's internal repository.
47- - file:
48- name: keys/sbuild-key.sec
49- description: |
50- Private key file for sbuild's internal repository.
51- It will be removed from the workspace after consuming.
52 axes:
53 - axis:
54 type: slave
55diff --git a/tests/fixtures/prepare/prepare-0-install.xml b/tests/fixtures/prepare/prepare-0-install.xml
56index dc191e8..85fdb61 100644
57--- a/tests/fixtures/prepare/prepare-0-install.xml
58+++ b/tests/fixtures/prepare/prepare-0-install.xml
59@@ -58,6 +58,8 @@ sudo apt-get install --yes \
60
61 # build tools as used in Launchpad
62 sudo add-apt-repository --yes ppa:launchpad/buildd-staging
63+sudo add-apt-repository --yes ppa:jenkaas-hackers/tools
64+
65 # backported tools (e.g. autopkgtest)
66 if [[ "amd64 i386" == *`dpkg-architecture -qDEB_HOST_ARCH`* ]]; then
67 sudo add-apt-repository --yes "deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse"
68diff --git a/tests/fixtures/prepare/prepare-1-sbuild.xml b/tests/fixtures/prepare/prepare-1-sbuild.xml
69index 7b22769..cb5569d 100644
70--- a/tests/fixtures/prepare/prepare-1-sbuild.xml
71+++ b/tests/fixtures/prepare/prepare-1-sbuild.xml
72@@ -26,16 +26,6 @@ the job will fail and needs to be ran again.
73 <name>configurations</name>
74 <description>Which slaves to run these steps on</description>
75 </hudson.plugins.matrix__configuration__parameter.MatrixCombinationsParameterDefinition>
76- <hudson.model.FileParameterDefinition>
77- <name>keys/sbuild-key.pub</name>
78- <description>Public key file for sbuild&apos;s internal repository.</description>
79- </hudson.model.FileParameterDefinition>
80- <hudson.model.FileParameterDefinition>
81- <name>keys/sbuild-key.sec</name>
82- <description>Private key file for sbuild's internal repository.
83-It will be removed from the workspace after consuming.
84-</description>
85- </hudson.model.FileParameterDefinition>
86 </parameterDefinitions>
87 </hudson.model.ParametersDefinitionProperty>
88 </properties>
89@@ -72,15 +62,8 @@ if ! ( id | fgrep -q &apos;(sbuild)&apos; ); then
90 # need to restart jenkins-slave if jenkins isn&apos;t in sbuild group yet
91 sudo initctl restart --no-wait jenkins-slave
92 else
93- # copy the public key file
94- [ -f keys/sbuild-key.pub ] &amp;&amp; sudo cp keys/sbuild-key.pub /var/lib/sbuild/apt-keys
95- [ -f keys/sbuild-key.sec ] &amp;&amp; sudo mv keys/sbuild-key.sec /var/lib/sbuild/apt-keys
96-
97- if ! [ -f /var/lib/sbuild/apt-keys/sbuild-key.pub -a -f /var/lib/sbuild/apt-keys/sbuild-key.sec ]; then
98- echo &quot;ERROR: You need to upload the sbuild archive keypair&quot;
99-
100- exit 1
101- fi
102+ # remove the keys, if any - new sbuild doesn't require them
103+ sudo rm -Rf /var/lib/sbuild/apt-keys
104
105 # prepare shared ccache directory
106 ccdir=/var/cache/ccache-sbuild

Subscribers

People subscribed via source and target branches