- job: name: tcwg-infra-update-home project-type: freestyle defaults: global description: | This job tracks changes to /home/tcwg-* files in ci/dockerfiles.git repository and updates machines in machine_list with new versions of the files. The files are .gitconfig, .ssh/*, etc. The update is done by fetching files from the repo using git-archive, and untarring them to /home directories of tcwg-infra users. properties: - authorization: anonymous: - job-read - job-extended-read linaro: - job-build - job-cancel - build-discarder: days-to-keep: 30 num-to-keep: 100 parameters: - label: name: nodes default: tcwg-build || tcwg-apm_64-build || tcwg-apm_64-test || tcwg-bmk-coordinator || tcwg-bmk-tk1_32 || tcwg-bmk-tx1_64 || tcwg-coordinator || tcwg-d05-01 || tcwg-sq_64-build || tcwg-tk1_32-build || tcwg-x86_64-build || tcwg-x86_64-cam all-nodes: true matching-label: 'allCases' node-eligibility: 'all' description: 'Machines to run on' disabled: false concurrent: false display-name: 'TCWG CCC Update TCWG Infra /home files' triggers: - gerrit: server-name: 'review.linaro.org' trigger-on: - change-merged-event projects: - project-compare-type: 'PLAIN' project-pattern: 'ci/dockerfiles' branches: - branch-pattern: 'tcwg-tested' file-paths: - compare-type: ANT pattern: tcwg-base/home-data/tcwg-buildslave/** - compare-type: ANT pattern: tcwg-base/home-data/tcwg-benchmark/** silent-start: true wrappers: - timeout: timeout: 600 - timestamps - ssh-agent-credentials: users: # tcwg-buildslave user id - 'e0958a95-204f-4c14-a66c-5e2be6c5d50a' - 'tcwg-benchmark' - build-name: name: '#${BUILD_NUMBER}-${NODE_NAME}' builders: - shell: | #!/bin/bash set -ex dir=$(mktemp -d) ssh -o StrictHostKeyChecking=no git@git.linaro.org true || true git archive --remote ssh://git@git.linaro.org/ci/dockerfiles.git HEAD > $dir.tar tar x --strip-components=2 -f $dir.tar -C $dir tcwg-base/home-data case "$NODE_NAME" in tcwg-bmk-dev-*) rsync_dest="" ;; tcwg-bmk-*) rsync_dest="tcwg-${NODE_NAME##tcwg-bmk-}.tcwglab:" ;; *) rsync_dest="" ;; esac rsync -aL $dir/$USER/ $rsync_dest/home/$USER/ rm -rf $dir/ $dir.tar publishers: - email-ext: recipients: tcwg-validation@linaro.org aborted: true