I would like to rebuild the whole fleet of integration-slave-docker instances for a few reasons:
- upgrade from Jessie to Stretch
- reduce RAM from 32 to 24 by switching the flavor from bigram to mediumram (available since T225025)
- in the hostname, replace slave by agent
- use /srv/jenkins/workspace (instead of jenkins-workspace)
Steps:
- On https://integration.wikimedia.org/ci/computer/ pick a node, put it offline, wait for jobs to complete and delete the agent
- On https://horizon.wikimedia.org/project/instances/
- Delete the instance
- Create a new instance named integration-agent-docker-XXX where XXXX increments starting from 1001
- Pick the Stretch image
- Pick mediumram flavor
Wait 3 or 4 minutes for the instance to be fully provisioned. Then on the instance:
- rm -fR /var/lib/puppet/ssl && puppet agent -tv
- if that complains:
- get the instance fully qualified domain name hostname --fqdn
- on integration-puppetmaster01.integration.eqiad.wmflabs: sudo puppet cert clean <FQDN OF INSTANCE HERE>
Apply the puppet role
- https://horizon.wikimedia.org/project/instances/
- Click the instance
- Puppet tab
- Pick role::ci::slave::labs::docker and set docker_lvm_volume to True
- Run puppet on the instance
- Make sure there is a /var/lib/docker partition for Docker
- Upgrade and reboot: sudo apt -y dist-upgrade && /usr/sbin/reboot
Add the instance to Jenkins
- Create node copying integration-agent-docker-1001
- Remote root directory is /srv/jenkins/workspace
- Change the IP address
- Once the master tries to connect, manually accept the ssh key from the side bar: Trust SSH Host Key