Skip to content

Instantly share code, notes, and snippets.

@rtnpro
Last active May 11, 2016 16:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rtnpro/e903918b78ba57634b8890996739d0b7 to your computer and use it in GitHub Desktop.
Save rtnpro/e903918b78ba57634b8890996739d0b7 to your computer and use it in GitHub Desktop.
Get started wth CentOS Community Container Pipeline Vagrant box

Setup

sudo yum install -y epel-release git
# We are installing Ansible from pip because there's a bug in Ansible Docker module in EPEL
sudo yum install -y ansible1.9
sudo yum install centos-release-scl qemu-kvm libvirt
sudo yum -y install sclo-vagrant1
sudo yum install python2-jenkins-job-builder

# start libvirtd
sudo systemctl start libvirtd; sudo systemctl enable libvirtd

# enable bash on vagrant scl
sudo scl enable sclo-vagrant1 bash

Deploy

git clone https://github.com/rtnpro/centos-cccp-ansible
cd centos-cccp-ansible
vagrant plugin install vagrant-hostmanager
vagrant up --no-provision
vagrant provision

Configure Jenkins Job Builder

Create file /etc/jenkins_jobs/jenkins_jobs.ini with content similar to:

[jenkins]
user=admin
password=admin
url=http://cccp-master.example.com:8080/

Push jobs to jenkins

  • Clone the repos in the same directory:

    • git clone https://github.com/bamachrn/cccp-service.git
    • git clone https://github.com/kbsingh/cccp-index.git

Then do:

cd cccp-service/jenkinsbuilder
python cccp_index_reader.py ../../cccp-index/index.yml

And wait for the jobs for the projects in the index to be pushed to Jenkins.

Setup

sudo yum install -y epel-release git
# We are installing Ansible from pip because there's a bug in Ansible Docker module in EPEL
sudo yum install -y ansible1.9
sudo yum install python2-jenkins-job-builder

Deploy

git clone https://github.com/rtnpro/centos-cccp-ansible
cd centos-cccp-ansible
cp hosts.sample hosts
# edit hosts as needed
ansible-playbook -i hosts -s vagrant.yml
@bamachrn
Copy link

bamachrn commented May 11, 2016

Few pre-setup steps:

  1. Need to copy ssh public key from deployer machine to all the three machines
    2.Need to comment out
    Defaults requiretty
    in /etc/sudoers for jenkins-slave and openshift server
  2. Add the certificate and key for registry.centos.org in /etc/pki/tls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment