# toolchain **Repository Path**: mirrors_apache/toolchain ## Basic Information - **Project Name**: toolchain - **Description**: Ansible - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-08-22 - **Last Updated**: 2025-10-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README

steps to execute ansible playbook to setup Apache Jenkins build slaves


step1

update the hosts file

``` [gkesavan@HW11151 ~/work/toolchain (master)]$ cat hosts [ubuntu-slaves] priapus.apache.org pomona.apache.org penates.apache.org pietas.apache.org proserpina.apache.org [hadoop-slaves] asf90[0:5].gq1.ygridcore.net asf9[06:11].gq1.ygridcore.net [ubuntu-slaves:vars] jdk_version=7 jvm_data_model=32 ansible_ssh_user= update_etc_hosts=false [hadoop-slaves:vars] jdk_version=6 jvm_data_model=64 ansible_ssh_user= update_etc_hosts=true [slaves:children] ubuntu-slaves hadoop-slaves ```

To run on specific hosts comment out other host info or other option is to commentout the label say ubuntu-slave , if only want to run the playbooks on hadoop-slaves. Also, set the to point to a userid that has sudo access on the slaves.


step2

update init.yml

If, execting ansible playbook for the first time you may have to enable couple to flags.

To setup p/w less ssh from master to slave

``` setup_master_key: true - add the path to the jenkins master pub key ```

To setup jenkins user with crypted password copy the password from one of the jenins slaves shadow file and paste it against

``` pass_word: and also set setup_password: true ```

and similary for setting up the clover license, installing jdk and copying nexus password for ci user


step3

To execute ansible playbooks.

``` ansible-playbook -i hosts init.yml ```

This would execute all the modules which doesnt have any tag definition.

``` ansible-playbook -i hosts init.yml -vv --tags install_libraries,update_configs ```

This would execute install_libraries and update_configs tags. Tags are defined for these two main task as we continue to update the configs and install new set of libraries. We can introduce more tags as needed.