]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
buildpackages: apply suse modifications
authorLoic Dachary <loic@dachary.org>
Tue, 7 Feb 2017 21:26:27 +0000 (22:26 +0100)
committerKyr Shatskyy <kyrylo.shatskyy@suse.com>
Mon, 14 Oct 2019 14:47:01 +0000 (16:47 +0200)
From https://github.com/SUSE/ceph-qa-suite/tree/wip-opensuse-jewel
because it is known to work. Omit the branch specification.

Signed-off-by: Loic Dachary <loic@dachary.org>
teuthology/task/buildpackages/make-rpm.sh
teuthology/task/buildpackages/sle-12.1-user-data.txt [new file with mode: 0644]
teuthology/task/buildpackages/sle-12.2-user-data.txt [new file with mode: 0644]

index 64f950fdc802261c675af38be20912af809ee7bc..f0286628306bda012f0f70f50f6a72a6be434035 100755 (executable)
@@ -32,9 +32,10 @@ arch=$6
 
 suse=false
 [[ $codename =~ suse ]] && suse=true
+[[ $codename =~ sle ]] && suse=true
 
 if [ "$suse" = true ] ; then
-    sudo zypper -n install git
+    sudo zypper -n install --no-recommends git
 else
     sudo yum install -y git
 fi
@@ -81,18 +82,20 @@ function build_package() {
     # included in the distribution.
     #
     git clean -qdxff
-    #
-    # creating the distribution tarbal requires some configure
-    # options (otherwise parts of the source tree will be left out).
-    #
-    if [ "$suse" = true ] ; then
-        sudo zypper -n install bzip2
-    else
-        sudo yum install -y bzip2
-    fi
     # autotools only works in jewel and below
     if [[ ! -e "make-dist" ]] ; then
+        # lsb-release is required by install-deps.sh 
+        # which is required by autogen.sh
+        if [ "$suse" = true ] ; then
+            sudo zypper -n install bzip2 lsb-release which
+        else
+            sudo yum install -y bzip2 redhat-lsb-core which
+        fi
         ./autogen.sh
+        #
+        # creating the distribution tarball requires some configure
+        # options (otherwise parts of the source tree will be left out).
+        #
         ./configure $(flavor2configure $flavor) --with-debug --with-radosgw --with-fuse --with-libatomic-ops --with-gtk2 --with-nss
 
         #
@@ -131,6 +134,7 @@ function build_package() {
                  -e '/^Epoch:/d' \
                  -e 's/%bcond_with ceph_test_package/%bcond_without ceph_test_package/' \
                  -e "s/^Source0:.*$/Source0: $CEPH_TARBALL/" \
+                 -e '/^Source9/d' \
                  ceph.spec
         fi
         buildarea=`readlink -fn ${releasedir}`   ### rpm wants absolute path
diff --git a/teuthology/task/buildpackages/sle-12.1-user-data.txt b/teuthology/task/buildpackages/sle-12.1-user-data.txt
new file mode 100644 (file)
index 0000000..9482dc4
--- /dev/null
@@ -0,0 +1,15 @@
+#cloud-config
+bootcmd:
+ - echo nameserver 8.8.8.8 | tee -a /etc/resolv.conf # last resort, in case the DHCP server does not provide a resolver
+ - SUSEConnect -p sle-sdk/12.2/x86_64
+manage_etc_hosts: true
+preserve_hostname: true
+users:
+  - name: ubuntu
+    gecos: User
+    sudo: ["ALL=(ALL) NOPASSWD:ALL"]
+    groups: users
+runcmd:
+ - ( MYHOME=/home/ubuntu ; mkdir $MYHOME/.ssh ; chmod 700 $MYHOME/.ssh ; cp /root/.ssh/authorized_keys $MYHOME/.ssh ; chown -R ubuntu.users $MYHOME/.ssh )
+ - zypper --non-interactive install --no-recommends python wget git ntp rsyslog lsb-release
+final_message: "READYTORUN"
diff --git a/teuthology/task/buildpackages/sle-12.2-user-data.txt b/teuthology/task/buildpackages/sle-12.2-user-data.txt
new file mode 100644 (file)
index 0000000..9482dc4
--- /dev/null
@@ -0,0 +1,15 @@
+#cloud-config
+bootcmd:
+ - echo nameserver 8.8.8.8 | tee -a /etc/resolv.conf # last resort, in case the DHCP server does not provide a resolver
+ - SUSEConnect -p sle-sdk/12.2/x86_64
+manage_etc_hosts: true
+preserve_hostname: true
+users:
+  - name: ubuntu
+    gecos: User
+    sudo: ["ALL=(ALL) NOPASSWD:ALL"]
+    groups: users
+runcmd:
+ - ( MYHOME=/home/ubuntu ; mkdir $MYHOME/.ssh ; chmod 700 $MYHOME/.ssh ; cp /root/.ssh/authorized_keys $MYHOME/.ssh ; chown -R ubuntu.users $MYHOME/.ssh )
+ - zypper --non-interactive install --no-recommends python wget git ntp rsyslog lsb-release
+final_message: "READYTORUN"