]> xenbits.xensource.com Git - openstack/ci-loop-config.git/commitdiff
Copy swift credentials from nodepool-scripts directory
authorBob Ball <bob.ball@citrix.com>
Tue, 16 Feb 2016 15:23:54 +0000 (15:23 +0000)
committerBob Ball <bob.ball@citrix.com>
Tue, 16 Feb 2016 15:23:54 +0000 (15:23 +0000)
install_master.sh
jenkins/jobs/macros-common.yaml
nodepool/nodepool.yaml
zuul/layout.yaml

index 780e9f4142ba9bfbc36acfc8d6bba8f0651f5c9f..c4c7ff3b4a8506a7f80d4aa703f7c6de7d0e15d9 100644 (file)
@@ -4,40 +4,47 @@ set -eux
 THIS_DIR=`pwd`
 DATA_PATH=/root/os-ext-data
 
+# This script and guide was taken from
+# http://docs.openstack.org/infra/openstackci/third_party_ci.html Feb
+# 2016 which may have additional debugging suggestions if there are
+# missing items
+
 # Steps to reinstall:
 # 1) Log in to mycloud.rackspace.com using credentials from os-ext-data/single_node_ci_data.yaml
 #    Search for 'username' and 'password' under the 'oscc_file_contents' setting
-# 1a) Create new Ubuntu 14.04 server (copy password), hostname 'jenkins-libvirt'
+# -- Create new Ubuntu 14.04 server (copy password), hostname 'jenkins-libvirt'
 #     7.5GB Compute v1 flavor
 #     Enable monitoring and security updates
-# 1b) Save the password for use in step 2a
-# 1c) Add key from os-ext-data/xenproject_jenkins.pub with the name 'xenproject-nodepool'
-# 2) Disable password authentication on jenkins server
-# 2a) ssh-copy-id to copy a key to the server
-# 2b) edit /etc/sshd_config to set "PermitRootLogin without-password"
-# 2c) service ssh restart
+# -- Save the password for use in step 2a
+# -- Add key from os-ext-data/xenproject_jenkins.pub with the name 'xenproject-nodepool'
+# 2) Initial server setup:
+# -- Disable password authentication on jenkins server
+# ---- ssh-copy-id to copy a key to the server
+# ---- edit /etc/sshd_config to set "PermitRootLogin without-password"
+# ---- service ssh restart
+# -- Add a 8GB swap file:
+# ---- fallocate -l 8G /swapfile; chmod 600 /swapfile; mkswap /swapfile; swapon /swapfile
+# ---- echo "/swapfile   none    swap    sw    0   0" >> /etc/fstab
 # 3) Copy the secret credentials dir (http://hg.uk.xensource.com/openstack/infrastructure.hg/os-ext-data) to /root/os-ext-data
 # 4) Clone this repo:
-# 4a) apt-get install git
-# 4b) git clone https://github.com/bobball/os-ext-testing.git
-# 4c) cd os-ext-testing
+# -- apt-get install git
+# -- git clone https://github.com/bobball/os-ext-testing.git
+# -- cd os-ext-testing
 # 5) Run below commands (or just this script) to do the 'standard' install
 # 6) The jobs need an additional plugin in Jenkins to generate correctly, so:
-# 6a) Install Post-Build Script jenkins plugin (including restarting Jenkins)
-# 6b) Regenerate jenkins jobs: jenkins-jobs update --delete-old /etc/jenkins_jobs/config
+# -- Install Post-Build Script jenkins plugin (including restarting Jenkins)
+# -- Regenerate jenkins jobs: jenkins-jobs update --delete-old /etc/jenkins_jobs/config
 # 7) Start processes
-# 7a) service zuul start; service zuul-merger start
-# 7b) Wait for a bit, check there are 3 zuul processes (1 merger, 2 servers)
-# 7c) service nodepool start
-# 7d) Wait for a bit (5m); check an image is being built (su - nodepool; nodepool image-list)
-# 7e) Wait for a lot (1h?); check a node is built (su - nodepool; nodepool list)
-# 7f) Check http://<ip> and http://<ip>:8080 to check that zuul + jenkins (respectively) are running
+# -- service zuul start; service zuul-merger start
+# -- Wait for a bit, check there are 3 zuul processes (1 merger, 2 servers)
+# -- service nodepool start
+# -- Wait for a bit (5m); check an image is being built (su - nodepool; nodepool image-list)
+# -- Wait for a lot (1h?); check a node is built (su - nodepool; nodepool list)
+# -- Check http://<ip> and http://<ip>:8080 to check that zuul + jenkins (respectively) are running
+# -- Enable gearman and ZMQ in Jenkins (Manage Jenkins --> Configure System) 
 # 8) Secure jenkins - instructions at end of http://docs.openstack.org/infra/openstackci/third_party_ci.html
 # ?) Set up monitoring checks https://intelligence.rackspace.com/
 
-# Copied from the following URL Feb 2016
-# http://docs.openstack.org/infra/openstackci/third_party_ci.html
-
 # Install puppet
 [ -e install_puppet.sh ] && rm install_puppet.sh
 wget https://git.openstack.org/cgit/openstack-infra/system-config/plain/install_puppet.sh
@@ -66,3 +73,6 @@ sed -i -e 's/^\(127\.0\.0\.1.*\)$/\1 jenkins/' /etc/hosts
 
 sudo puppet apply --verbose /etc/puppet/manifests/site.pp
 
+# Copy the osci config file (which includes the swift API key) to the
+# nodepool-scripts directory so it will be added to nodes.
+cp /root/os-ext-data/osci.config /etc/nodepool/scripts
index 9c4a3f741845c6c602a41f8978f6fc026313c5f8..f514767b5d237eed2e85ad7fc211de0cedc72869 100644 (file)
           # CA bundle in 2.5.2 is broken
           pip install --upgrade requests>2.5.2
           sudo mkdir -p /etc/osci/
-          cat | sudo tee /etc/osci/osci.config >/dev/null << EOF
-          SWIFT_API_KEY=<%= @swift_api_key %>
-          SWIFT_USERNAME=<%= @swift_api_user %>
-          SWIFT_REGION=IAD
-          SWIFT_CONTAINER=XenLogs
-          EOF
+          sudo cp /opt/nodepool-scripts/osci.config /etc/osci/osci.config
           osci-upload /tmp/console.html {upload_source} $LOG_PATH
 
 
index 1c6ffbdea6d22eb3dbd97a52d716e22f637696cd..672d8e5891550962749650c6b9dd012a5c1b6bb6 100644 (file)
@@ -26,7 +26,7 @@ gearman-servers:
 labels:
   - name: ds-xen
     image: ds-xen
-    min-ready: 2
+    min-ready: 1
     providers:
       - name: rax-iad
 
index 9e1b3eb3d6d1eb6b3cefbdc056305333eea8787b..b6cdf3e4a9c33f2027b876e0ce65171750528dd3 100644 (file)
@@ -23,6 +23,8 @@ pipelines:
       gerrit:
         verified: -1
     merge-failure:
+      gerrit:
+        verified: -1
       smtp:
         to: openstack-ci@xenproject.org
         from: zuul@zuul.openstack.xenproject.org